From b1f825e6b97713d207fa290a0b2843972e31df91 Mon Sep 17 00:00:00 2001 From: zosimovaa Date: Thu, 12 Mar 2026 20:40:29 +0300 Subject: [PATCH] =?UTF-8?q?=D0=A4=D0=B8=D0=BA=D1=81=D0=B8=D1=80=D1=83?= =?UTF-8?q?=D0=B5=D0=BC=20=D1=81=D0=BE=D1=81=D1=82=D0=BE=D1=8F=D0=BD=D0=B8?= =?UTF-8?q?=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../agent/code_qa_runtime/answer_policy.py | 35 +- .../modules/agent/code_qa_runtime/executor.py | 274 +- .../agent/code_qa_runtime/post_gate.py | 205 + .../code_qa_runtime/prompt_payload_builder.py | 76 + .../modules/agent/code_qa_runtime/repair.py | 23 + .../code_qa_runtime/short_answer_formatter.py | 33 + .../prompts/code_qa_architecture_answer.txt | 10 +- .../agent/prompts/code_qa_explain_answer.txt | 8 +- .../code_qa_find_entrypoints_answer.txt | 2 + .../agent/prompts/code_qa_repair_answer.txt | 6 + .../prompts/code_qa_trace_flow_answer.txt | 6 +- .../code_qa_pipeline/answer_fact_curator.py | 300 + .../rag/code_qa_pipeline/answer_synthesis.py | 18 +- .../modules/rag/code_qa_pipeline/contracts.py | 3 + .../evidence_bundle_builder.py | 1 + .../retrieval_result_builder.py | 234 +- src/app/modules/shared/gigachat/settings.py | 2 +- .../test_code_qa_answer_boundary.py | 323 ++ tests/pipeline_setup_v2/core/artifacts.py | 13 +- .../pipeline_setup_v2/core/test_validators.py | 27 + ...lba_code_subintents_one_per_subintent.yaml | 121 + tests/pipeline_setup_v3/core/artifacts.py | 16 +- .../pipeline_setup_v3/core/test_validators.py | 27 + .../runtime/agent_runtime_adapter.py | 15 + .../manual_run/20260312_193339.zip | Bin 0 -> 137913 bytes ...plba-v3-architecture-runtime-manager.json} | 432 +- ...nt_plba-v3-architecture-runtime-manager.md | 305 ++ ...t_plba-v3-explain-local-http-channel.json} | 232 +- ...tent_plba-v3-explain-local-http-channel.md | 285 + ...tent_plba-v3-explain-runtime-manager.json} | 406 +- ...bintent_plba-v3-explain-runtime-manager.md | 311 ++ ...-v3-find-entrypoints-health-endpoint.json} | 368 +- ...lba-v3-find-entrypoints-health-endpoint.md | 261 + ...t_plba-v3-find-tests-runtime-manager.json} | 232 +- ...tent_plba-v3-find-tests-runtime-manager.md | 269 + ..._subintent_plba-v3-open-file-runtime.json} | 101 +- ...per_subintent_plba-v3-open-file-runtime.md | 250 + ...ent_plba-v3-trace-flow-runtime-start.json} | 410 +- ...intent_plba-v3-trace-flow-runtime-start.md | 305 ++ .../manual_run/20260312_193339/summary.md | 36 + ...s_v2_plba-v2-architecture-control-plane.md | 34 - ...v2_plba-v2-architecture-runtime-manager.md | 34 - ...tents_v2_plba-v2-explain-create-runtime.md | 34 - ...v2_plba-v2-explain-local-http-channel.json | 2033 ------- ...s_v2_plba-v2-explain-local-http-channel.md | 34 - ...v2_plba-v2-explain-nonexistent-symbol.json | 4092 -------------- ...s_v2_plba-v2-explain-nonexistent-symbol.md | 36 - ...ents_v2_plba-v2-explain-runtime-manager.md | 34 - ...ents_v2_plba-v2-explain-trace-service.json | 4157 -------------- ...ntents_v2_plba-v2-explain-trace-service.md | 34 - ...lba-v2-find-entrypoints-control-plane.json | 1303 ----- ..._plba-v2-find-entrypoints-control-plane.md | 33 - ...lba-v2-find-entrypoints-health-endpoint.md | 32 - ...ts_v2_plba-v2-find-tests-create-runtime.md | 32 - ...s_v2_plba-v2-find-tests-runtime-manager.md | 32 - ...s_v2_plba-v2-find-tests-trace-service.json | 3134 ----------- ...nts_v2_plba-v2-find-tests-trace-service.md | 32 - ...tests-workflow-runtime-factory-negative.md | 32 - ...ntents_v2_plba-v2-open-file-nonexistent.md | 31 - ...tents_v2_plba-v2-open-file-public-api.json | 419 -- ...intents_v2_plba-v2-open-file-public-api.md | 30 - ...subintents_v2_plba-v2-open-file-runtime.md | 30 - ...v2_plba-v2-trace-flow-health-endpoint.json | 4707 ---------------- ...s_v2_plba-v2-trace-flow-health-endpoint.md | 35 - ...s_v2_plba-v2-trace-flow-runtime-start.json | 4868 ----------------- ...nts_v2_plba-v2-trace-flow-runtime-start.md | 34 - .../20260312_162307/summary.md | 86 - ...v2_plba-v2-architecture-control-plane.json | 4171 -------------- ...s_v2_plba-v2-architecture-control-plane.md | 34 - ..._plba-v2-architecture-runtime-manager.json | 4363 --------------- ...v2_plba-v2-architecture-runtime-manager.md | 34 - ...nts_v2_plba-v2-explain-create-runtime.json | 3779 ------------- ...tents_v2_plba-v2-explain-create-runtime.md | 34 - ...s_v2_plba-v2-explain-local-http-channel.md | 34 - ...v2_plba-v2-explain-nonexistent-symbol.json | 4092 -------------- ...s_v2_plba-v2-explain-nonexistent-symbol.md | 36 - ...ents_v2_plba-v2-explain-runtime-manager.md | 34 - ...ents_v2_plba-v2-explain-trace-service.json | 4157 -------------- ...ntents_v2_plba-v2-explain-trace-service.md | 34 - ..._plba-v2-find-entrypoints-control-plane.md | 33 - ...lba-v2-find-entrypoints-health-endpoint.md | 32 - ..._v2_plba-v2-find-tests-create-runtime.json | 2746 ---------- ...ts_v2_plba-v2-find-tests-create-runtime.md | 32 - ...v2_plba-v2-find-tests-runtime-manager.json | 3133 ----------- ...s_v2_plba-v2-find-tests-runtime-manager.md | 32 - ...s_v2_plba-v2-find-tests-trace-service.json | 3134 ----------- ...nts_v2_plba-v2-find-tests-trace-service.md | 32 - ...sts-workflow-runtime-factory-negative.json | 3001 ---------- ...tests-workflow-runtime-factory-negative.md | 32 - ...ents_v2_plba-v2-open-file-nonexistent.json | 341 -- ...ntents_v2_plba-v2-open-file-nonexistent.md | 31 - ...tents_v2_plba-v2-open-file-public-api.json | 417 -- ...intents_v2_plba-v2-open-file-public-api.md | 30 - ...bintents_v2_plba-v2-open-file-runtime.json | 417 -- ...subintents_v2_plba-v2-open-file-runtime.md | 30 - ...v2_plba-v2-trace-flow-health-endpoint.json | 4707 ---------------- ...s_v2_plba-v2-trace-flow-health-endpoint.md | 35 - ...nts_v2_plba-v2-trace-flow-runtime-start.md | 34 - .../20260312_162842/summary.md | 85 - ...v2_plba-v2-architecture-control-plane.json | 4171 -------------- ...s_v2_plba-v2-architecture-control-plane.md | 34 - ...v2_plba-v2-architecture-runtime-manager.md | 34 - ...nts_v2_plba-v2-explain-create-runtime.json | 3779 ------------- ...tents_v2_plba-v2-explain-create-runtime.md | 34 - ...s_v2_plba-v2-explain-local-http-channel.md | 34 - ...v2_plba-v2-explain-nonexistent-symbol.json | 4092 -------------- ...s_v2_plba-v2-explain-nonexistent-symbol.md | 36 - ...ts_v2_plba-v2-explain-runtime-manager.json | 4154 -------------- ...ents_v2_plba-v2-explain-runtime-manager.md | 34 - ...ntents_v2_plba-v2-explain-trace-service.md | 34 - ...lba-v2-find-entrypoints-control-plane.json | 1303 ----- ..._plba-v2-find-entrypoints-control-plane.md | 33 - ...lba-v2-find-entrypoints-health-endpoint.md | 32 - ..._v2_plba-v2-find-tests-create-runtime.json | 2746 ---------- ...ts_v2_plba-v2-find-tests-create-runtime.md | 32 - ...s_v2_plba-v2-find-tests-runtime-manager.md | 32 - ...nts_v2_plba-v2-find-tests-trace-service.md | 32 - ...sts-workflow-runtime-factory-negative.json | 3001 ---------- ...tests-workflow-runtime-factory-negative.md | 32 - ...ntents_v2_plba-v2-open-file-nonexistent.md | 31 - ...intents_v2_plba-v2-open-file-public-api.md | 30 - ...subintents_v2_plba-v2-open-file-runtime.md | 30 - ...s_v2_plba-v2-trace-flow-health-endpoint.md | 35 - ...nts_v2_plba-v2-trace-flow-runtime-start.md | 34 - .../20260312_163609/summary.md | 85 - ...s_v2_plba-v2-architecture-control-plane.md | 247 - ...tents_v2_plba-v2-explain-create-runtime.md | 247 - ...s_v2_plba-v2-explain-local-http-channel.md | 223 - ..._plba-v2-find-entrypoints-control-plane.md | 195 - ...lba-v2-find-entrypoints-health-endpoint.md | 194 - ...ts_v2_plba-v2-find-tests-create-runtime.md | 211 - ...nts_v2_plba-v2-find-tests-trace-service.md | 211 - ...intents_v2_plba-v2-open-file-public-api.md | 188 - ...subintents_v2_plba-v2-open-file-runtime.md | 188 - ...s_v2_plba-v2-trace-flow-health-endpoint.md | 248 - ...nts_v2_plba-v2-trace-flow-runtime-start.md | 247 - .../20260312_164751/summary.md | 84 - ...v2_plba-v2-architecture-control-plane.json | 177 +- ...s_v2_plba-v2-architecture-control-plane.md | 305 ++ ..._plba-v2-architecture-runtime-manager.json | 177 +- ...v2_plba-v2-architecture-runtime-manager.md | 305 ++ ...nts_v2_plba-v2-explain-create-runtime.json | 181 +- ...tents_v2_plba-v2-explain-create-runtime.md | 305 ++ ...v2_plba-v2-explain-local-http-channel.json | 102 +- ...s_v2_plba-v2-explain-local-http-channel.md | 285 + ...v2_plba-v2-explain-nonexistent-symbol.json | 632 +++ ..._v2_plba-v2-explain-nonexistent-symbol.md} | 166 +- ...ts_v2_plba-v2-explain-runtime-manager.json | 177 +- ...ents_v2_plba-v2-explain-runtime-manager.md | 305 ++ ...ents_v2_plba-v2-explain-trace-service.json | 181 +- ...ntents_v2_plba-v2-explain-trace-service.md | 305 ++ ...lba-v2-find-entrypoints-control-plane.json | 284 +- ..._plba-v2-find-entrypoints-control-plane.md | 262 + ...a-v2-find-entrypoints-health-endpoint.json | 285 +- ...lba-v2-find-entrypoints-health-endpoint.md | 261 + ..._v2_plba-v2-find-tests-create-runtime.json | 94 +- ...ts_v2_plba-v2-find-tests-create-runtime.md | 269 + ...v2_plba-v2-find-tests-runtime-manager.json | 94 +- ...s_v2_plba-v2-find-tests-runtime-manager.md | 269 + ...s_v2_plba-v2-find-tests-trace-service.json | 98 +- ...nts_v2_plba-v2-find-tests-trace-service.md | 269 + ...sts-workflow-runtime-factory-negative.json | 82 +- ...tests-workflow-runtime-factory-negative.md | 76 +- ...ents_v2_plba-v2-open-file-nonexistent.json | 78 +- ...ntents_v2_plba-v2-open-file-nonexistent.md | 76 +- ...tents_v2_plba-v2-open-file-public-api.json | 176 +- ...intents_v2_plba-v2-open-file-public-api.md | 250 + ...bintents_v2_plba-v2-open-file-runtime.json | 176 +- ...subintents_v2_plba-v2-open-file-runtime.md | 250 + ...v2_plba-v2-trace-flow-health-endpoint.json | 181 +- ...s_v2_plba-v2-trace-flow-health-endpoint.md | 306 ++ ...s_v2_plba-v2-trace-flow-runtime-start.json | 181 +- ...nts_v2_plba-v2-trace-flow-runtime-start.md | 305 ++ .../20260312_174008/summary.md | 80 + ...v2_plba-v2-architecture-control-plane.json | 424 +- ...s_v2_plba-v2-architecture-control-plane.md | 307 ++ ..._plba-v2-architecture-runtime-manager.json | 447 +- ...v2_plba-v2-architecture-runtime-manager.md | 116 +- ...nts_v2_plba-v2-explain-create-runtime.json | 384 +- ...tents_v2_plba-v2-explain-create-runtime.md | 305 ++ ...v2_plba-v2-explain-local-http-channel.json | 226 +- ...s_v2_plba-v2-explain-local-http-channel.md | 285 + ...v2_plba-v2-explain-nonexistent-symbol.json | 123 +- ...s_v2_plba-v2-explain-nonexistent-symbol.md | 90 +- ...ts_v2_plba-v2-explain-runtime-manager.json | 408 +- ...ents_v2_plba-v2-explain-runtime-manager.md | 315 ++ ...ents_v2_plba-v2-explain-trace-service.json | 404 +- ...ntents_v2_plba-v2-explain-trace-service.md | 311 ++ ...lba-v2-find-entrypoints-control-plane.json | 204 +- ..._plba-v2-find-entrypoints-control-plane.md | 262 + ...a-v2-find-entrypoints-health-endpoint.json | 362 +- ...lba-v2-find-entrypoints-health-endpoint.md | 261 + ..._v2_plba-v2-find-tests-create-runtime.json | 226 +- ...ts_v2_plba-v2-find-tests-create-runtime.md | 269 + ...v2_plba-v2-find-tests-runtime-manager.json | 226 +- ...s_v2_plba-v2-find-tests-runtime-manager.md | 269 + ...s_v2_plba-v2-find-tests-trace-service.json | 226 +- ...nts_v2_plba-v2-find-tests-trace-service.md | 269 + ...sts-workflow-runtime-factory-negative.json | 212 +- ...ests-workflow-runtime-factory-negative.md} | 118 +- ...ents_v2_plba-v2-open-file-nonexistent.json | 171 +- ...ntents_v2_plba-v2-open-file-nonexistent.md | 245 + ...tents_v2_plba-v2-open-file-public-api.json | 95 +- ...intents_v2_plba-v2-open-file-public-api.md | 250 + ...bintents_v2_plba-v2-open-file-runtime.json | 177 +- ...subintents_v2_plba-v2-open-file-runtime.md | 250 + ...v2_plba-v2-trace-flow-health-endpoint.json | 409 +- ...s_v2_plba-v2-trace-flow-health-endpoint.md | 306 ++ ...s_v2_plba-v2-trace-flow-runtime-start.json | 404 +- ...nts_v2_plba-v2-trace-flow-runtime-start.md | 305 ++ .../20260312_192715/summary.md | 80 + ...t_case_plba-v2-open-file-nonexistent.json} | 170 +- ...last_case_plba-v2-open-file-nonexistent.md | 245 + .../20260312_165845/summary.md | 12 + ...us_plba-v2-explain-nonexistent-symbol.json | 632 +++ ...cus_plba-v2-explain-nonexistent-symbol.md} | 166 +- ...-v2-find-entrypoints-health-endpoint.json} | 361 +- ...lba-v2-find-entrypoints-health-endpoint.md | 261 + .../20260312_173122/summary.md | 16 + .../tmp/full_chain_plba_quality_focus.yaml | 36 + 220 files changed, 23993 insertions(+), 92568 deletions(-) create mode 100644 src/app/modules/agent/code_qa_runtime/short_answer_formatter.py create mode 100644 src/app/modules/rag/code_qa_pipeline/answer_fact_curator.py create mode 100644 tests/pipeline_setup/suite_02_pipeline/pipeline_intent_rag/test_code_qa_answer_boundary.py create mode 100644 tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339.zip rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.json} (91%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.json} (89%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.json} (93%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.json} (75%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.json} (94%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.json} (85%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json => manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.json} (93%) create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.md create mode 100644 tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/summary.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/summary.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/summary.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/summary.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md delete mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/summary.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json (95%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json (95%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json (95%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json (93%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md => 20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md} (54%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json (96%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json (96%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162842 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json (87%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json (79%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json (96%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json (97%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json (97%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json (98%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md (69%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json (83%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md (67%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json (69%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json (79%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json (96%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_174008}/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json (96%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/summary.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json (90%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json (92%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md (52%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json (91%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json (89%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json (84%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md (70%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json (93%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json (93%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json (90%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json (75%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json (93%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json (94%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json (94%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json (95%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md => 20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md} (57%) rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_162307 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json (65%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_164751 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json (78%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json (79%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json (93%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md rename tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/{20260312_163609 => 20260312_192715}/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json (93%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md create mode 100644 tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/summary.md rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json => plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.json} (65%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.md create mode 100644 tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/summary.md create mode 100644 tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.json rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md => plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.md} (52%) rename tests/pipeline_setup_v3/test_results/{plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json => plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.json} (74%) create mode 100644 tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.md create mode 100644 tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/summary.md create mode 100644 tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml diff --git a/src/app/modules/agent/code_qa_runtime/answer_policy.py b/src/app/modules/agent/code_qa_runtime/answer_policy.py index a7cb4db..f4f6c7e 100644 --- a/src/app/modules/agent/code_qa_runtime/answer_policy.py +++ b/src/app/modules/agent/code_qa_runtime/answer_policy.py @@ -4,6 +4,7 @@ from dataclasses import dataclass from app.modules.rag.code_qa_pipeline.evidence_gate import EvidenceGateDecision from app.modules.rag.intent_router_v2.models import IntentRouterResult +from app.modules.agent.code_qa_runtime.short_answer_formatter import CodeQaShortAnswerFormatter @dataclass(slots=True, frozen=True) @@ -16,6 +17,9 @@ class CodeQaPolicyDecision: class CodeQaAnswerPolicy: + def __init__(self, formatter: CodeQaShortAnswerFormatter | None = None) -> None: + self._formatter = formatter or CodeQaShortAnswerFormatter() + def decide( self, *, @@ -29,34 +33,39 @@ class CodeQaAnswerPolicy: target = path_scope[0] if path_scope else "запрошенный файл" return CodeQaPolicyDecision( answer_mode="not_found", - answer=f"Файл {target} не найден.", + answer=self._formatter.open_file_not_found(target), should_call_llm=False, branch="open_file_not_found", reason="path_scope_empty", ) - if sub_intent == "EXPLAIN" and symbol_resolution.status in {"not_found", "ambiguous"}: + if sub_intent == "EXPLAIN" and symbol_resolution.status == "not_found": return CodeQaPolicyDecision( - answer_mode="degraded", - answer=self._symbol_message(symbol_resolution.status, symbol_resolution.alternatives), + answer_mode="not_found", + answer=self._formatter.entity_not_found(self._target_label(router_result), symbol_resolution.alternatives), should_call_llm=False, - branch="explain_unresolved_symbol", - reason=f"symbol_resolution_{symbol_resolution.status}", + branch="explain_not_found", + reason="symbol_resolution_not_found", + ) + if sub_intent == "EXPLAIN" and symbol_resolution.status == "ambiguous": + return CodeQaPolicyDecision( + answer_mode="ambiguous", + answer=self._formatter.entity_ambiguous(self._target_label(router_result), symbol_resolution.alternatives), + should_call_llm=False, + branch="explain_ambiguous_symbol", + reason="symbol_resolution_ambiguous", ) if not gate_decision.passed: answer_mode = "insufficient" if "insufficient_evidence" in gate_decision.failure_reasons else "degraded" reason = gate_decision.failure_reasons[0] if gate_decision.failure_reasons else "evidence_gate_failed" return CodeQaPolicyDecision( answer_mode=answer_mode, - answer=gate_decision.degraded_message, + answer=self._formatter.insufficient(gate_decision.degraded_message), should_call_llm=False, branch="evidence_gate_short_circuit", reason=reason, ) return CodeQaPolicyDecision(answer_mode="normal", branch="normal_answer", reason="evidence_sufficient") - def _symbol_message(self, status: str, alternatives: list[str]) -> str: - if status == "ambiguous" and alternatives: - return f"Сущность не удалось однозначно разрешить. Близкие варианты: {', '.join(alternatives[:3])}." - if alternatives: - return f"Сущность не найдена в доступном коде. Ближайшие варианты: {', '.join(alternatives[:3])}." - return "Сущность не найдена в доступном коде." + def _target_label(self, router_result: IntentRouterResult) -> str: + candidates = [item.strip() for item in list(router_result.query_plan.symbol_candidates or []) if item and item.strip()] + return candidates[0] if candidates else "запрошенная сущность" diff --git a/src/app/modules/agent/code_qa_runtime/executor.py b/src/app/modules/agent/code_qa_runtime/executor.py index 2b9944b..626464e 100644 --- a/src/app/modules/agent/code_qa_runtime/executor.py +++ b/src/app/modules/agent/code_qa_runtime/executor.py @@ -1,6 +1,7 @@ from __future__ import annotations import logging +from difflib import SequenceMatcher from time import perf_counter from app.modules.agent.code_qa_runtime.answer_policy import CodeQaAnswerPolicy @@ -50,6 +51,9 @@ class CodeQaRuntimeExecutor: def execute(self, *, user_query: str, rag_session_id: str, files_map: dict[str, dict] | None = None) -> CodeQaFinalResult: timings_ms: dict[str, int] = {} runtime_trace: list[dict] = [] + answer_policy_branch = "" + decision_reason = "" + post_gate_snapshot: dict = {} state = CodeQaExecutionState( user_query=user_query, rag_session_id=rag_session_id, @@ -76,9 +80,10 @@ class CodeQaRuntimeExecutor: started = perf_counter() raw_rows = self._retrieve(state) timings_ms["retrieval"] = self._elapsed_ms(started) + retrieval_report = self._retrieval.consume_retrieval_report() or {} + raw_rows, retrieval_report = self._hydrate_entrypoint_sources(state, raw_rows, retrieval_report) symbol_resolution = self._resolve_symbol(state.router_result.symbol_resolution.model_dump(), raw_rows) state.router_result = state.router_result.model_copy(update={"symbol_resolution": SymbolResolution(**symbol_resolution)}) - retrieval_report = self._retrieval.consume_retrieval_report() state.retrieval_result = build_retrieval_result(raw_rows, retrieval_report, symbol_resolution) if state.retrieval_request.sub_intent.upper() == "EXPLAIN" and symbol_resolution.get("status") in {"not_found", "ambiguous"}: state.retrieval_result = build_retrieval_result([], retrieval_report, symbol_resolution) @@ -101,8 +106,10 @@ class CodeQaRuntimeExecutor: if state.retrieval_request.sub_intent.upper() == "EXPLAIN" and symbol_resolution.get("status") in {"not_found", "ambiguous"}: state.evidence_pack.sufficient = False state.evidence_pack.failure_reasons = ["target_not_resolved"] + pre_gate_input = self._build_pre_gate_input(state) + started = perf_counter() gate_decision = evaluate_evidence(state.evidence_pack) - timings_ms["pre_evidence_gate"] = 0 + timings_ms["pre_evidence_gate"] = self._elapsed_ms(started) state.answer_mode = "normal" if gate_decision.passed else "degraded" state.degraded_message = gate_decision.degraded_message runtime_trace.append( @@ -110,31 +117,51 @@ class CodeQaRuntimeExecutor: "step": "pre_evidence_gate", "status": "passed" if gate_decision.passed else "blocked", "timings_ms": {"pre_evidence_gate": timings_ms["pre_evidence_gate"]}, + "input": pre_gate_input, "output": { "passed": gate_decision.passed, "failure_reasons": list(gate_decision.failure_reasons), "degraded_message": gate_decision.degraded_message, + "evidence_count": state.evidence_pack.evidence_count, }, } ) decision = self._answer_policy.decide(router_result=state.router_result, gate_decision=gate_decision) + answer_policy_branch = decision.branch + decision_reason = decision.reason if not decision.should_call_llm: state.answer_mode = decision.answer_mode + started = perf_counter() runtime_trace.append( { "step": "llm", "status": "skipped", + "timings_ms": {"llm": self._elapsed_ms(started)}, "output": { "reason": "policy_short_circuit", "answer_mode": decision.answer_mode, + "decision_reason": decision.reason, + "answer_policy_branch": decision.branch, }, } ) + started = perf_counter() + timings_ms["post_evidence_gate"] = self._elapsed_ms(started) + post_gate_snapshot = { + "input": { + "answer_mode": decision.answer_mode, + "draft_present": False, + "resolved_target": self._resolved_target(state), + }, + "output": {"reason": "no_draft_answer"}, + } runtime_trace.append( { "step": "post_evidence_gate", "status": "skipped", - "output": {"reason": "no_draft_answer"}, + "timings_ms": {"post_evidence_gate": timings_ms["post_evidence_gate"]}, + "input": post_gate_snapshot["input"], + "output": post_gate_snapshot["output"], } ) return self._finalize( @@ -145,13 +172,41 @@ class CodeQaRuntimeExecutor: llm_used=False, timings_ms=timings_ms, runtime_trace=runtime_trace, + answer_policy_branch=answer_policy_branch, + decision_reason=decision_reason, + pre_gate_input=pre_gate_input, + gate_decision=gate_decision, + post_gate_snapshot=post_gate_snapshot, ) if self._llm is None: + answer_policy_branch = "llm_unavailable" + decision_reason = "llm_service_missing" + started = perf_counter() runtime_trace.append( { "step": "llm", "status": "skipped", - "output": {"reason": "llm_unavailable"}, + "timings_ms": {"llm": self._elapsed_ms(started)}, + "output": {"reason": "llm_unavailable", "answer_policy_branch": answer_policy_branch, "decision_reason": decision_reason}, + } + ) + started = perf_counter() + timings_ms["post_evidence_gate"] = self._elapsed_ms(started) + post_gate_snapshot = { + "input": { + "answer_mode": state.answer_mode, + "draft_present": False, + "resolved_target": self._resolved_target(state), + }, + "output": {"reason": "no_draft_answer"}, + } + runtime_trace.append( + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": {"post_evidence_gate": timings_ms["post_evidence_gate"]}, + "input": post_gate_snapshot["input"], + "output": post_gate_snapshot["output"], } ) return self._finalize( @@ -162,6 +217,11 @@ class CodeQaRuntimeExecutor: llm_used=False, timings_ms=timings_ms, runtime_trace=runtime_trace, + answer_policy_branch=answer_policy_branch, + decision_reason=decision_reason, + pre_gate_input=pre_gate_input, + gate_decision=gate_decision, + post_gate_snapshot=post_gate_snapshot, ) state.synthesis_input = build_answer_synthesis_input(user_query, state.evidence_pack) prompt_name = self._prompt_selector.select(sub_intent=state.retrieval_request.sub_intent, answer_mode=state.answer_mode) @@ -186,10 +246,29 @@ class CodeQaRuntimeExecutor: "output": { "prompt_name": prompt_name, "answer_preview": draft.answer[:300], + "resolved_target": self._resolved_target(state), + "answer_policy_branch": answer_policy_branch, + "decision_reason": decision_reason, }, } ) - validation = self._post_gate.validate(answer=draft.answer, answer_mode=state.answer_mode, degraded_message=state.degraded_message) + post_gate_input = { + "answer_mode": state.answer_mode, + "degraded_message": state.degraded_message, + "resolved_target": self._resolved_target(state), + "draft_answer_preview": draft.answer[:300], + "repair_candidate": bool(self._repair is not None), + } + started = perf_counter() + validation = self._post_gate.validate( + answer=draft.answer, + answer_mode=state.answer_mode, + degraded_message=state.degraded_message, + sub_intent=state.retrieval_request.sub_intent, + user_query=user_query, + evidence_pack=state.evidence_pack, + ) + timings_ms["post_evidence_gate"] = self._elapsed_ms(started) final_answer = draft.answer repair_used = False if not validation.passed and self._repair is not None: @@ -197,22 +276,40 @@ class CodeQaRuntimeExecutor: final_answer = self._repair.repair(draft_answer=draft.answer, validation=validation, prompt_payload=prompt_payload) repair_used = True timings_ms["repair"] = self._elapsed_ms(started) - validation = self._post_gate.validate(answer=final_answer, answer_mode=state.answer_mode, degraded_message=state.degraded_message) - if not validation.passed and state.degraded_message: - final_answer = state.degraded_message + started = perf_counter() + validation = self._post_gate.validate( + answer=final_answer, + answer_mode=state.answer_mode, + degraded_message=state.degraded_message, + sub_intent=state.retrieval_request.sub_intent, + user_query=user_query, + evidence_pack=state.evidence_pack, + ) + timings_ms["post_evidence_gate_recheck"] = self._elapsed_ms(started) + if not validation.passed: + final_answer = self._fallback_answer(state) + state.answer_mode = self._fallback_mode(state) + post_gate_snapshot = { + "input": post_gate_input, + "output": { + "passed": validation.passed, + "action": validation.action, + "reasons": list(validation.reasons), + "repair_used": repair_used, + "final_answer_preview": final_answer[:300], + }, + } runtime_trace.append( { "step": "post_evidence_gate", "status": "passed" if validation.passed else "failed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": timings_ms["post_evidence_gate"], + "post_evidence_gate_recheck": timings_ms.get("post_evidence_gate_recheck", 0), "repair": timings_ms.get("repair", 0), }, - "output": { - "passed": validation.passed, - "reasons": list(validation.reasons), - "repair_used": repair_used, - }, + "input": post_gate_snapshot["input"], + "output": post_gate_snapshot["output"], } ) return self._finalize( @@ -224,6 +321,11 @@ class CodeQaRuntimeExecutor: validation=validation, timings_ms=timings_ms, runtime_trace=runtime_trace, + answer_policy_branch=answer_policy_branch, + decision_reason=decision_reason, + pre_gate_input=pre_gate_input, + gate_decision=gate_decision, + post_gate_snapshot=post_gate_snapshot, ) def _retrieve(self, state: CodeQaExecutionState) -> list[dict]: @@ -257,9 +359,10 @@ class CodeQaRuntimeExecutor: exact = next((item for item in found if item in candidates), None) if exact: return {"status": "resolved", "resolved_symbol": exact, "alternatives": found[:5], "confidence": 0.99} - if found: - return {"status": "ambiguous", "resolved_symbol": None, "alternatives": found[:5], "confidence": 0.55} - return {"status": "not_found", "resolved_symbol": None, "alternatives": [], "confidence": 0.0} + close = self._close_matches(candidates, found) + if close: + return {"status": "ambiguous", "resolved_symbol": None, "alternatives": close[:5], "confidence": 0.55} + return {"status": "not_found", "resolved_symbol": None, "alternatives": close[:5], "confidence": 0.0} def _finalize( self, @@ -272,6 +375,11 @@ class CodeQaRuntimeExecutor: validation=None, timings_ms: dict[str, int] | None = None, runtime_trace: list[dict] | None = None, + answer_policy_branch: str = "", + decision_reason: str = "", + pre_gate_input: dict | None = None, + gate_decision=None, + post_gate_snapshot: dict | None = None, ) -> CodeQaFinalResult: diagnostics = build_diagnostics_report( router_result=state.router_result, @@ -280,6 +388,11 @@ class CodeQaRuntimeExecutor: evidence_bundle=state.evidence_pack, answer_mode=state.answer_mode, timings_ms=timings_ms or {}, + resolved_target=self._resolved_target(state), + answer_policy_branch=answer_policy_branch, + decision_reason=decision_reason, + evidence_gate_input=pre_gate_input or {}, + post_evidence_gate=post_gate_snapshot or {}, ) result = CodeQaFinalResult( final_answer=final_answer.strip(), @@ -287,7 +400,15 @@ class CodeQaRuntimeExecutor: repair_used=repair_used, llm_used=llm_used, draft_answer=draft, - validation=validation or self._post_gate.validate(answer=final_answer, answer_mode=state.answer_mode, degraded_message=state.degraded_message), + validation=validation + or self._post_gate.validate( + answer=final_answer, + answer_mode=state.answer_mode, + degraded_message=state.degraded_message, + sub_intent=state.retrieval_request.sub_intent if state.retrieval_request else "", + user_query=state.user_query, + evidence_pack=state.evidence_pack, + ), router_result=state.router_result, retrieval_request=state.retrieval_request, retrieval_result=state.retrieval_result, @@ -306,4 +427,119 @@ class CodeQaRuntimeExecutor: return result def _elapsed_ms(self, started: float) -> int: - return int((perf_counter() - started) * 1000) + return max(1, round((perf_counter() - started) * 1000)) + + def _build_pre_gate_input(self, state: CodeQaExecutionState) -> dict: + evidence = state.evidence_pack + retrieval = state.retrieval_result + return { + "resolved_target": self._resolved_target(state), + "sub_intent": state.retrieval_request.sub_intent if state.retrieval_request else None, + "target_type": evidence.target_type if evidence else None, + "evidence_count": evidence.evidence_count if evidence else 0, + "code_chunk_count": len(evidence.code_chunks) if evidence else 0, + "entrypoint_count": len(evidence.entrypoints) if evidence else 0, + "relation_count": len(evidence.relations) if evidence else 0, + "test_evidence_count": len(evidence.test_evidence) if evidence else 0, + "symbol_resolution_status": retrieval.symbol_resolution_status if retrieval else None, + "path_scope": list(state.retrieval_request.path_scope) if state.retrieval_request else [], + } + + def _resolved_target(self, state: CodeQaExecutionState) -> str | None: + if state.evidence_pack and state.evidence_pack.resolved_target: + return state.evidence_pack.resolved_target + if state.retrieval_result and state.retrieval_result.resolved_symbol: + return state.retrieval_result.resolved_symbol + if state.retrieval_request and state.retrieval_request.path_scope: + return state.retrieval_request.path_scope[0] + return None + + def _close_matches(self, candidates: list[str], found: list[str]) -> list[str]: + ranked: list[tuple[float, str]] = [] + for candidate in candidates: + for item in found: + score = SequenceMatcher(None, candidate.lower(), item.lower()).ratio() + if score >= 0.52: + ranked.append((score, item)) + ranked.sort(key=lambda pair: (-pair[0], pair[1])) + result: list[str] = [] + for _, item in ranked: + if item not in result: + result.append(item) + return result + + def _hydrate_entrypoint_sources( + self, + state: CodeQaExecutionState, + raw_rows: list[dict], + retrieval_report: dict, + ) -> tuple[list[dict], dict]: + if not state.retrieval_request or state.retrieval_request.sub_intent.upper() != "FIND_ENTRYPOINTS": + return raw_rows, retrieval_report + entrypoint_paths = [] + for row in raw_rows: + if str(row.get("layer") or "") != "C3_ENTRYPOINTS": + continue + path = str(row.get("path") or "").strip() + if path and path not in entrypoint_paths: + entrypoint_paths.append(path) + if not entrypoint_paths: + return raw_rows, retrieval_report + extra_rows = self._retrieval.retrieve_exact_files( + state.rag_session_id, + paths=entrypoint_paths[:3], + layers=["C0_SOURCE_CHUNKS"], + limit=24, + query=state.user_query, + ranking_profile="entrypoint_source_hydration", + ) + extra_report = self._retrieval.consume_retrieval_report() or {} + return self._merge_rows(raw_rows, extra_rows), self._merge_reports(retrieval_report, extra_report) + + def _merge_rows(self, base_rows: list[dict], extra_rows: list[dict]) -> list[dict]: + merged: list[dict] = [] + seen: set[tuple[str, str, str, int | None, int | None]] = set() + for row in [*base_rows, *extra_rows]: + key = ( + str(row.get("layer") or ""), + str(row.get("path") or ""), + str(row.get("title") or ""), + row.get("span_start"), + row.get("span_end"), + ) + if key in seen: + continue + seen.add(key) + merged.append(row) + return merged + + def _merge_reports(self, base: dict, extra: dict) -> dict: + merged = dict(base or {}) + merged["executed_layers"] = list(dict.fromkeys([*(base.get("executed_layers") or []), *(extra.get("executed_layers") or [])])) + merged["retrieval_mode_by_layer"] = {**dict(base.get("retrieval_mode_by_layer") or {}), **dict(extra.get("retrieval_mode_by_layer") or {})} + merged["top_k_by_layer"] = {**dict(base.get("top_k_by_layer") or {}), **dict(extra.get("top_k_by_layer") or {})} + merged["filters_by_layer"] = {**dict(base.get("filters_by_layer") or {}), **dict(extra.get("filters_by_layer") or {})} + merged["retrieval_by_layer_ms"] = {**dict(base.get("retrieval_by_layer_ms") or {}), **dict(extra.get("retrieval_by_layer_ms") or {})} + merged["fallback"] = dict(extra.get("fallback") or base.get("fallback") or {"used": False, "reason": None}) + merged["supplemental_requests"] = [*(base.get("supplemental_requests") or []), *(extra.get("requests") or [])] + return merged + + def _fallback_mode(self, state: CodeQaExecutionState) -> str: + status = str(state.router_result.symbol_resolution.status if state.router_result and state.router_result.symbol_resolution else "") + if status == "ambiguous": + return "ambiguous" + if status == "not_found": + return "not_found" + return "degraded" + + def _fallback_answer(self, state: CodeQaExecutionState) -> str: + symbol_resolution = state.router_result.symbol_resolution if state.router_result else None + query_plan = state.router_result.query_plan if state.router_result else None + target = next((item for item in list(query_plan.symbol_candidates or []) if item), "запрошенная сущность") if query_plan else "запрошенная сущность" + if symbol_resolution and symbol_resolution.status == "ambiguous": + return self._answer_policy.decide(router_result=state.router_result, gate_decision=evaluate_evidence(state.evidence_pack)).answer + if symbol_resolution and symbol_resolution.status == "not_found": + return self._answer_policy.decide(router_result=state.router_result, gate_decision=evaluate_evidence(state.evidence_pack)).answer + if state.degraded_message: + return state.degraded_message + return f"Недостаточно подтверждённых данных для уверенного ответа по {target}." diff --git a/src/app/modules/agent/code_qa_runtime/post_gate.py b/src/app/modules/agent/code_qa_runtime/post_gate.py index bcb0d30..a30e4d1 100644 --- a/src/app/modules/agent/code_qa_runtime/post_gate.py +++ b/src/app/modules/agent/code_qa_runtime/post_gate.py @@ -1,6 +1,25 @@ from __future__ import annotations +import re + from app.modules.agent.code_qa_runtime.models import CodeQaValidationResult +from app.modules.rag.code_qa_pipeline.answer_fact_curator import build_curated_answer_facts +from app.modules.rag.code_qa_pipeline.contracts import EvidenceBundle + +_TOKEN_RE = re.compile(r"[a-zA-Zа-яА-Я0-9_/]+") +_VAGUE_PHRASES = ( + "ряд аргументов", + "имеет responsibilities", + "имеет responsibility", + "ключевой компонент", + "центральный компонент", + "играет роль", + "управляет системой", + "этап пайплайна", + "инициализация сервисов", + "регистрация основных служб", +) +_OPTIMISTIC_TRACE_CLAIMS = ("полностью восстанавливается", "полный поток выполнения", "полностью прослеживается") class CodeQaPostEvidenceGate: @@ -10,6 +29,9 @@ class CodeQaPostEvidenceGate: answer: str, answer_mode: str, degraded_message: str, + sub_intent: str, + user_query: str, + evidence_pack: EvidenceBundle | None, ) -> CodeQaValidationResult: normalized = (answer or "").strip() if not normalized: @@ -18,6 +40,189 @@ class CodeQaPostEvidenceGate: return CodeQaValidationResult(passed=False, action="repair", reasons=["degraded_answer_missing_guardrail"]) if answer_mode == "not_found" and "не найден" not in normalized.lower(): return CodeQaValidationResult(passed=False, action="repair", reasons=["not_found_answer_missing_phrase"]) + if answer_mode == "ambiguous" and "не удалось однозначно разрешить" not in normalized.lower(): + return CodeQaValidationResult(passed=False, action="repair", reasons=["ambiguous_answer_missing_phrase"]) if degraded_message and answer_mode != "normal" and len(normalized) < 24: return CodeQaValidationResult(passed=False, action="repair", reasons=["answer_too_short"]) + if answer_mode != "normal" or evidence_pack is None: + return CodeQaValidationResult(passed=True, action="return") + + reasons = self._normal_answer_reasons(normalized.lower(), sub_intent.upper(), user_query, evidence_pack) + if reasons: + return CodeQaValidationResult(passed=False, action="repair", reasons=_dedupe(reasons)) return CodeQaValidationResult(passed=True, action="return") + + def _normal_answer_reasons(self, answer: str, sub_intent: str, user_query: str, evidence_pack: EvidenceBundle) -> list[str]: + reasons: list[str] = [] + if sub_intent == "FIND_ENTRYPOINTS": + reasons.extend(self._validate_entrypoints(answer, user_query, evidence_pack)) + elif sub_intent == "EXPLAIN": + reasons.extend(self._validate_explain(answer, evidence_pack)) + elif sub_intent == "ARCHITECTURE": + reasons.extend(self._validate_architecture(answer, evidence_pack)) + elif sub_intent == "TRACE_FLOW": + reasons.extend(self._validate_trace_flow(answer, evidence_pack)) + return reasons + + def _validate_entrypoints(self, answer: str, user_query: str, evidence_pack: EvidenceBundle) -> list[str]: + confirmed = [item for item in list(evidence_pack.entrypoints or []) if item.get("http_method") and item.get("route_path")] + if not confirmed: + return [] + query_tokens = self._tokens(user_query) + matched = [item for item in confirmed if self._tokens(str(item.get("route_path") or "")) & query_tokens] + required = matched or confirmed[:1] + reasons = [] + if any(f"{item['http_method']} {item['route_path']}".lower() not in answer for item in required): + reasons.append("missing_confirmed_route") + if matched and any(token in query_tokens for token in {"health", "/health"}) and "не обнаруж" in answer: + reasons.append("contradicts_confirmed_route") + return reasons + + def _validate_explain(self, answer: str, evidence_pack: EvidenceBundle) -> list[str]: + facts = build_curated_answer_facts(evidence_pack) + explain = dict(facts.get("explain") or {}) + reasons = self._validate_target_focus(answer, evidence_pack) + reasons.extend(self._vagueness_reasons(answer, "explain")) + + matches = 0 + methods = list(explain.get("required_methods") or []) + calls = list(explain.get("required_calls") or []) + dependencies = list(explain.get("required_dependencies") or []) + fields = list(explain.get("required_fields") or []) + if methods and not self._mentions_fact_group(answer, methods): + reasons.append("missing_concrete_methods") + elif methods: + matches += 1 + if calls and not self._mentions_fact_group(answer, calls): + reasons.append("missing_concrete_calls") + elif calls: + matches += 1 + if dependencies and not self._mentions_fact_group(answer, dependencies): + reasons.append("missing_concrete_dependencies") + elif dependencies: + matches += 1 + if fields and self._mentions_fact_group(answer, fields): + matches += 1 + if (methods or calls or dependencies or fields) and matches == 0: + reasons.append("too_vague_for_explain") + if self._semantic_leakage(answer, facts, has_concrete_support=matches > 0): + reasons.append("semantic_labels_without_code_edges") + return reasons + + def _validate_architecture(self, answer: str, evidence_pack: EvidenceBundle) -> list[str]: + facts = build_curated_answer_facts(evidence_pack) + architecture = dict(facts.get("architecture") or {}) + reasons = self._validate_target_focus(answer, evidence_pack) + reasons.extend(self._vagueness_reasons(answer, "architecture")) + + components = list(architecture.get("required_components") or []) + relations = list(architecture.get("required_relations") or []) + verbs = list(architecture.get("required_relation_verbs") or []) + if components and not self._mentions_fact_group(answer, components): + reasons.append("missing_concrete_components") + if relations and not self._mentions_relations(answer, relations): + reasons.append("missing_concrete_relations") + if verbs and not self._mentions_fact_group(answer, verbs): + reasons.append("missing_relation_verbs") + if any(label in answer for label in architecture.get("forbidden_labels") or []): + reasons.append("contains_retrieval_artifacts") + if self._methods_dominate_components(answer, components): + reasons.append("methods_as_primary_components") + if relations and (not self._mentions_relations(answer, relations) or not self._mentions_fact_group(answer, verbs)): + reasons.append("too_vague_for_architecture") + if self._semantic_leakage(answer, facts, has_concrete_support=self._mentions_relations(answer, relations)): + reasons.append("semantic_labels_without_code_edges") + return reasons + + def _validate_trace_flow(self, answer: str, evidence_pack: EvidenceBundle) -> list[str]: + facts = build_curated_answer_facts(evidence_pack) + trace = dict(facts.get("trace_flow") or {}) + reasons = self._validate_target_focus(answer, evidence_pack) + reasons.extend(self._vagueness_reasons(answer, "trace_flow")) + + steps = list(trace.get("required_flow_steps") or []) + calls = list(trace.get("required_calls") or []) + if steps and not self._mentions_steps(answer, steps): + reasons.append("missing_flow_steps") + if calls and not self._mentions_fact_group(answer, calls): + reasons.append("missing_concrete_calls") + if steps and not self._mentions_relations(answer, steps): + reasons.append("missing_sequence_edges") + if any(claim in answer for claim in _OPTIMISTIC_TRACE_CLAIMS): + reasons.append("overclaims_trace_completeness") + if steps and not (self._mentions_steps(answer, steps) and self._mentions_relations(answer, steps)): + reasons.append("too_vague_for_trace_flow") + return reasons + + def _validate_target_focus(self, answer: str, evidence_pack: EvidenceBundle) -> list[str]: + target = str(evidence_pack.resolved_target or "").strip().lower() + return [] if not target or target in answer else ["missing_resolved_target"] + + def _mentions_fact_group(self, answer: str, values: list[str]) -> bool: + return any(alias in answer for value in values for alias in _aliases(value)) + + def _mentions_relations(self, answer: str, relations: list[dict]) -> bool: + for relation in relations: + source = str(relation.get("source") or "").lower() + target = str(relation.get("target") or "").lower() + verb = str(relation.get("verb") or "").lower() + if source and target and source in answer and target in answer: + return True + if source and verb and target and source in answer and verb in answer and target in answer: + return True + return False + + def _mentions_steps(self, answer: str, steps: list[dict]) -> bool: + if "сначала" in answer and "затем" in answer: + return True + numeric_steps = sum(1 for marker in ("1.", "2.", "3.") if marker in answer) + if numeric_steps >= 2: + return True + mentioned = sum(1 for step in steps[:3] if self._mentions_relations(answer, [step])) + return mentioned >= min(2, len(steps[:3])) + + def _methods_dominate_components(self, answer: str, components: list[str]) -> bool: + method_like = re.findall(r"\b[a-z_]+\(\)", answer) + component_hits = sum(1 for component in components if component.lower() in answer) + return bool(method_like) and component_hits == 0 + + def _semantic_leakage(self, answer: str, facts: dict, *, has_concrete_support: bool) -> bool: + if has_concrete_support: + return False + semantic_roles = [str(item.get("role") or "").strip().lower() for item in facts.get("semantic_hints") or [] if str(item.get("role") or "").strip()] + return bool(semantic_roles) and any(role in answer for role in semantic_roles) + + def _vagueness_reasons(self, answer: str, scenario: str) -> list[str]: + if any(phrase in answer for phrase in _VAGUE_PHRASES): + return [f"too_vague_for_{scenario}"] + return [] + + def _tokens(self, value: str) -> set[str]: + return {token.lower().strip("/") for token in _TOKEN_RE.findall(value or "") if token.strip("/")} + + +def _aliases(value: str) -> list[str]: + text = str(value or "").strip().lower() + if not text: + return [] + aliases = [text] + bare = text.removesuffix("()") + if bare != text: + aliases.append(bare) + tail = bare.rsplit(".", 1)[-1] + if tail and tail not in aliases: + aliases.append(tail) + if tail and f"{tail}()" not in aliases: + aliases.append(f"{tail}()") + return aliases + + +def _dedupe(values: list[str]) -> list[str]: + seen: set[str] = set() + result: list[str] = [] + for value in values: + if value in seen: + continue + seen.add(value) + result.append(value) + return result diff --git a/src/app/modules/agent/code_qa_runtime/prompt_payload_builder.py b/src/app/modules/agent/code_qa_runtime/prompt_payload_builder.py index 2711cd3..4e1fb31 100644 --- a/src/app/modules/agent/code_qa_runtime/prompt_payload_builder.py +++ b/src/app/modules/agent/code_qa_runtime/prompt_payload_builder.py @@ -1,6 +1,7 @@ from __future__ import annotations import json +import re from app.modules.rag.code_qa_pipeline.contracts import AnswerSynthesisInput, EvidenceBundle @@ -11,6 +12,7 @@ _LAYER_GUIDE = ( "- C3_ENTRYPOINTS: подтвержденные точки входа.\n" "- C4_SEMANTIC_ROLES: вспомогательная роль компонента, использовать осторожно." ) +_TOKEN_RE = re.compile(r"[a-zA-Zа-яА-Я0-9_/]+") class CodeQaPromptPayloadBuilder: @@ -30,8 +32,82 @@ class CodeQaPromptPayloadBuilder: "fast_context": synthesis_input.fast_context, "deep_context": synthesis_input.deep_context, "evidence_summary": synthesis_input.evidence_summary, + "semantic_hints": synthesis_input.semantic_hints, "diagnostic_hints": synthesis_input.diagnostic_hints, "retrieval_summary": evidence_pack.retrieval_summary, + "confirmed_entrypoints": self._entrypoints(user_query, evidence_pack), + "required_entrypoints": self._required_entrypoints(user_query, evidence_pack), "layer_guide": _LAYER_GUIDE, } + payload.update(self._scenario_payload(synthesis_input)) return json.dumps(payload, ensure_ascii=False, indent=2) + + def _entrypoints(self, user_query: str, evidence_pack: EvidenceBundle) -> list[dict]: + query_tokens = self._tokens(user_query) + enriched: list[dict] = [] + for item in list(evidence_pack.entrypoints or []): + route_path = str(item.get("route_path") or "").strip() + http_method = str(item.get("http_method") or "").strip().upper() + if not http_method: + continue + candidate = { + "http_method": http_method, + "route_path": route_path, + "display": f"{http_method} {route_path}".strip(), + "handler_symbol": str(item.get("handler_symbol") or "").strip(), + "path": str(item.get("path") or "").strip(), + "start_line": item.get("start_line"), + "end_line": item.get("end_line"), + "query_match": self._matches_query(route_path, query_tokens), + } + if candidate not in enriched: + enriched.append(candidate) + return sorted(enriched, key=lambda item: (-int(bool(item["query_match"])), -int(bool(item["route_path"])), len(item["route_path"] or "/"), item["display"])) + + def _required_entrypoints(self, user_query: str, evidence_pack: EvidenceBundle) -> list[str]: + return [item["display"] for item in self._entrypoints(user_query, evidence_pack) if item["query_match"] and item["route_path"]] + + def _scenario_payload(self, synthesis_input: AnswerSynthesisInput) -> dict: + scenario = (synthesis_input.resolved_scenario or "").upper() + curated = dict(synthesis_input.curated_facts or {}) + if scenario == "EXPLAIN": + facts = dict(curated.get("explain") or {}) + return { + "must_mention_methods": facts.get("required_methods", []), + "must_mention_fields": facts.get("required_fields", []), + "must_mention_calls": facts.get("required_calls", []), + "must_mention_dependencies": facts.get("required_dependencies", []), + "must_mention_constructor_args": facts.get("required_constructor_args", []), + "must_mention_files": facts.get("required_files", []), + "must_not_infer_missing_details": True, + "fact_gaps": facts.get("fact_gaps", []), + } + if scenario == "ARCHITECTURE": + facts = dict(curated.get("architecture") or {}) + return { + "must_mention_components": facts.get("required_components", []), + "must_mention_relations": facts.get("required_relations", []), + "must_use_relation_verbs": facts.get("required_relation_verbs", []), + "must_avoid_semantic_labels_as_primary_claims": True, + "must_not_use_retrieval_labels": facts.get("forbidden_labels", []), + "fact_gaps": facts.get("fact_gaps", []), + } + if scenario == "TRACE_FLOW": + facts = dict(curated.get("trace_flow") or {}) + return { + "must_mention_flow_steps": facts.get("required_flow_steps", []), + "must_mention_calls": facts.get("required_calls", []), + "must_mention_sequence_edges": facts.get("required_sequence_edges", []), + "must_avoid_overclaiming_full_flow": True, + "fact_gaps": facts.get("fact_gaps", []), + } + return {} + + def _matches_query(self, route_path: str, query_tokens: set[str]) -> bool: + if not route_path: + return False + path_tokens = self._tokens(route_path) + return bool(path_tokens & query_tokens) + + def _tokens(self, value: str) -> set[str]: + return {token.lower().strip("/") for token in _TOKEN_RE.findall(value or "") if token.strip("/")} diff --git a/src/app/modules/agent/code_qa_runtime/repair.py b/src/app/modules/agent/code_qa_runtime/repair.py index af8b39d..55eb6a7 100644 --- a/src/app/modules/agent/code_qa_runtime/repair.py +++ b/src/app/modules/agent/code_qa_runtime/repair.py @@ -17,10 +17,12 @@ class CodeQaAnswerRepairService: validation: CodeQaValidationResult, prompt_payload: str, ) -> str: + repair_focus = self._repair_focus(validation.reasons) repair_input = json.dumps( { "draft_answer": draft_answer, "validation_reasons": validation.reasons, + "repair_focus": repair_focus, "prompt_payload": prompt_payload, }, ensure_ascii=False, @@ -31,3 +33,24 @@ class CodeQaAnswerRepairService: repair_input, log_context="graph.project_qa.code_qa.repair", ).strip() + + def _repair_focus(self, reasons: list[str]) -> list[str]: + mapping = { + "missing_concrete_methods": "missing_concrete_methods", + "missing_concrete_calls": "missing_concrete_calls", + "missing_concrete_dependencies": "missing_concrete_dependencies", + "missing_concrete_components": "missing_concrete_components", + "missing_concrete_relations": "missing_concrete_relations", + "missing_relation_verbs": "missing_relation_verbs", + "missing_flow_steps": "missing_flow_steps", + "missing_sequence_edges": "missing_sequence_edges", + "too_vague_for_explain": "too_vague_for_explain", + "too_vague_for_architecture": "too_vague_for_architecture", + "too_vague_for_trace_flow": "too_vague_for_trace_flow", + "semantic_labels_without_code_edges": "semantic_labels_without_code_edges", + "contains_retrieval_artifacts": "contains_retrieval_artifacts", + "methods_as_primary_components": "methods_as_primary_components", + "overclaims_trace_completeness": "overclaims_trace_completeness", + } + result = [mapping[reason] for reason in reasons if reason in mapping] + return result or ["tighten_to_evidence"] diff --git a/src/app/modules/agent/code_qa_runtime/short_answer_formatter.py b/src/app/modules/agent/code_qa_runtime/short_answer_formatter.py new file mode 100644 index 0000000..7cdb83a --- /dev/null +++ b/src/app/modules/agent/code_qa_runtime/short_answer_formatter.py @@ -0,0 +1,33 @@ +from __future__ import annotations + + +class CodeQaShortAnswerFormatter: + def open_file_not_found(self, target: str) -> str: + return f"Файл {target} не найден." + + def entity_not_found(self, target: str, alternatives: list[str]) -> str: + base = f"Сущность {target} не найдена в доступном коде." + suffix = self._alternatives(alternatives) + return f"{base} {suffix}".strip() + + def entity_ambiguous(self, target: str, alternatives: list[str]) -> str: + base = f"Сущность {target} не удалось однозначно разрешить." + suffix = self._alternatives(alternatives) + return f"{base} {suffix}".strip() + + def insufficient(self, message: str) -> str: + normalized = (message or "").strip() + if normalized: + return normalized + return "Недостаточно подтверждённых данных для уверенного ответа." + + def related_only(self, target: str, alternatives: list[str]) -> str: + base = f"Прямых подтверждений для сущности {target} не найдено." + suffix = self._alternatives(alternatives) + return f"{base} {suffix}".strip() + + def _alternatives(self, alternatives: list[str]) -> str: + items = [item.strip() for item in alternatives if item and item.strip()] + if not items: + return "" + return f"Близкие варианты: {', '.join(items[:3])}." diff --git a/src/app/modules/agent/prompts/code_qa_architecture_answer.txt b/src/app/modules/agent/prompts/code_qa_architecture_answer.txt index d12911c..efe1ca8 100644 --- a/src/app/modules/agent/prompts/code_qa_architecture_answer.txt +++ b/src/app/modules/agent/prompts/code_qa_architecture_answer.txt @@ -17,9 +17,15 @@ Не выводи пустые разделы, пустые списки и формулировки вида "кандидатов нет", если это не помогает ответу. Дай архитектурное объяснение без лишней теории. -Назови подтверждённые компоненты и конкретные связи между ними: создаёт, вызывает, регистрирует, читает, пишет, передаёт, оборачивает. +Строй ответ вокруг concrete facts из payload: `must_mention_components`, `must_mention_relations`, `must_use_relation_verbs`. +Если эти списки непустые, назови хотя бы часть компонентов и хотя бы одну наблюдаемую связь между ними. +Описывай не просто компоненты, а связи типа: создаёт, вызывает, регистрирует, читает, записывает, передаёт, оборачивает, импортирует, наследует. +Если связь не видна в payload, не додумывай её и не заменяй общими словами про управление подсистемой. +Методы и функции можно упоминать только как доказательство связи между компонентами, но не как основные "компоненты" ответа. Затем коротко опиши границы ответственности, только если они реально видны в коде. Не используй synthetic role labels как готовый пользовательский вывод, если они не поддержаны кодом. Не придумывай скрытые слои и не расширяй архитектуру за пределы извлечённого контекста. Не используй обязательные markdown-секции. -Не используй абстрактные формулы вроде "главный компонент", "центральный управляющий компонент", "управляет потоками данных и состоянием системы", если конкретная связь не раскрыта через наблюдаемые методы, поля или вызовы. +Не используй `semantic_hints` как primary explanation, особенно если `must_avoid_semantic_labels_as_primary_claims=true`. +Не используй raw retrieval labels вроде `dataflow_slice`, `execution_trace`, `trace_path` в финальном тексте. +Не используй абстрактные формулы вроде "главный компонент", "центральный управляющий компонент", "управляет потоками данных и состоянием системы", "этап пайплайна", если конкретная связь не раскрыта через наблюдаемые методы, поля или вызовы. diff --git a/src/app/modules/agent/prompts/code_qa_explain_answer.txt b/src/app/modules/agent/prompts/code_qa_explain_answer.txt index 187c63d..d9e7fcb 100644 --- a/src/app/modules/agent/prompts/code_qa_explain_answer.txt +++ b/src/app/modules/agent/prompts/code_qa_explain_answer.txt @@ -18,9 +18,15 @@ Объясни, как работает сущность из вопроса пользователя, обычным инженерным текстом. Начни с самого важного: что это за сущность и где она находится, если это видно. -Затем кратко опиши подтверждённые зависимости, вызовы, аргументы, поля или шаги работы, только если они реально видны. +Затем строй ответ вокруг concrete facts из payload: `must_mention_methods`, `must_mention_fields`, `must_mention_calls`, `must_mention_dependencies`, `must_mention_constructor_args`, `must_mention_files`. +Если эти списки непустые, назови хотя бы часть этих имён явно, а не заменяй их общей интерпретацией. +Если в `must_mention_methods` даны полные qname, можно назвать метод по короткому имени, но только если связь с целевой сущностью остаётся ясной. +Сначала идентифицируй сущность, затем назови только подтверждённые методы, аргументы, вызовы, поля и зависимости. +Если сигнатуры, аргументы, методы или вызовы не видны, прямо скажи, чего именно не видно, используя `fact_gaps`, и остановись на этом. Не используй общие формулы без конкретных имён. Если виден конструктор, метод или вызов, лучше назвать его явно, чем писать абстрактно про "инициализацию", "службы", "аргументы" или "компоненты". Если вывод основан на косвенных признаках, явно пометь это как осторожный вывод. Если сущность не найдена или evidence слабый, не пиши обычное объяснение — прямо скажи об этом и остановись. +Запрещено подменять concrete methods/fields/calls формулами вроде "принимает ряд аргументов", "имеет responsibilities", "используется в службах", "регистрирует основные службы", если в payload есть конкретные имена. +Не используй `semantic_hints` как основной каркас ответа. Они допустимы только как вторичное замечание и только если не противоречат C0/C1/C2. Не используй обязательные секции и подзаголовки. diff --git a/src/app/modules/agent/prompts/code_qa_find_entrypoints_answer.txt b/src/app/modules/agent/prompts/code_qa_find_entrypoints_answer.txt index 1a2be57..4f1bce3 100644 --- a/src/app/modules/agent/prompts/code_qa_find_entrypoints_answer.txt +++ b/src/app/modules/agent/prompts/code_qa_find_entrypoints_answer.txt @@ -19,6 +19,8 @@ Найди точки входа, обработчики запуска или важные entrypoints. Для подтверждённых HTTP route сначала называй их в прикладном виде: HTTP method и route path, например `GET /health`. Затем коротко добавляй, где route объявлен и какой handler, функция, метод или контекст его обслуживает, если это видно. +Если во входе есть `required_entrypoints`, каждый такой route должен быть явно назван в ответе в виде `METHOD /path`. +Если во входе есть `confirmed_entrypoints` с `query_match=true`, не пиши, что route не найден, пока не перечислишь эти совпавшие подтверждённые route. Подтверждённые entrypoints перечисляй первыми. Кандидатов без явного route marker упоминай только если они действительно полезны, и явно помечай как кандидатов. Не своди ответ к обсуждению декораторов вроде `@app.get`; пользователю важнее method, path и контекст. diff --git a/src/app/modules/agent/prompts/code_qa_repair_answer.txt b/src/app/modules/agent/prompts/code_qa_repair_answer.txt index 437b50d..ca3b60f 100644 --- a/src/app/modules/agent/prompts/code_qa_repair_answer.txt +++ b/src/app/modules/agent/prompts/code_qa_repair_answer.txt @@ -1,3 +1,9 @@ Ты исправляешь черновой ответ по коду после проверки groundedness. Сделай ответ короче, точнее и строже по evidence payload. Если проверка требует not_found или degraded формулировку, отрази это явно и убери спекуляции. +Если в `repair_focus` есть причины для `EXPLAIN`, перепиши ответ так, чтобы он назвал concrete methods, calls, fields, constructor args или dependencies из payload, а не общие responsibilities. +Если в `repair_focus` есть причины для `ARCHITECTURE`, перепиши ответ так, чтобы он назвал concrete components и связи с relation verbs из payload: создает, вызывает, читает, записывает, импортирует, наследует. +Если в `repair_focus` есть причины для `TRACE_FLOW`, перепиши ответ как последовательность concrete steps с явными methods/calls/edges из payload. Если виден только partial flow, так и скажи. +Если в `repair_focus` есть `semantic_labels_without_code_edges`, убери semantic role labels из основной формулировки, если они не подкреплены concrete code edges. +Если в `repair_focus` есть `contains_retrieval_artifacts` или `methods_as_primary_components`, убери raw retrieval labels и не выдавай методы за компоненты. +Если в `repair_focus` есть `overclaims_trace_completeness`, убери фразы про полный/полностью восстановленный flow, если payload не подтверждает это явно. diff --git a/src/app/modules/agent/prompts/code_qa_trace_flow_answer.txt b/src/app/modules/agent/prompts/code_qa_trace_flow_answer.txt index 91be153..88c201c 100644 --- a/src/app/modules/agent/prompts/code_qa_trace_flow_answer.txt +++ b/src/app/modules/agent/prompts/code_qa_trace_flow_answer.txt @@ -17,7 +17,9 @@ Не выводи пустые разделы, пустые списки и формулировки вида "кандидатов нет", если это не помогает ответу. Проследи поток выполнения или поток данных по найденным артефактам. -Старайся описывать шаги последовательно и коротко, без лишних подзаголовков. +Строй ответ вокруг `must_mention_flow_steps`, `must_mention_calls` и `must_mention_sequence_edges` из payload. +Старайся описывать шаги последовательно и коротко, без лишних подзаголовков: сначала, затем, после этого, в конце. Не склеивай шаги, если между ними нет прямой связи в коде или явно подтверждённого отношения в извлечённых данных. -Если поток восстанавливается только частично, так и скажи. +Если поток восстанавливается только частично, так и скажи, опираясь на `fact_gaps`, и не заявляй, что flow восстановлен полностью. Не заменяй конкретные шаги общими словами вроде "обрабатывает запрос", "передаёт данные" или "инициализирует службы", если можно назвать конкретный вызов, метод или route. +Не используй сильные формулировки вроде "полностью восстанавливается", "полный поток виден", если payload показывает только часть цепочки. diff --git a/src/app/modules/rag/code_qa_pipeline/answer_fact_curator.py b/src/app/modules/rag/code_qa_pipeline/answer_fact_curator.py new file mode 100644 index 0000000..59038db --- /dev/null +++ b/src/app/modules/rag/code_qa_pipeline/answer_fact_curator.py @@ -0,0 +1,300 @@ +from __future__ import annotations + +import re +from typing import Any + +from app.modules.rag.code_qa_pipeline.contracts import CodeChunkItem, EvidenceBundle + +_CALL_RE = re.compile(r"([A-Za-z_][\w\.]*)\s*\(") +_FIELD_RE = re.compile(r"self\.(\w+)") +_SIGNATURE_RE = re.compile(r"(?P[A-Za-z_][\w\.]*)\((?P[^)]*)\)") +_RETRIEVAL_LABELS = ("dataflow_slice", "execution_trace", "trace_path") +_RELATION_VERBS = { + "calls": "вызывает", + "instantiates": "создает", + "inherits": "наследует", + "imports": "импортирует", + "reads_attr": "читает", + "writes_attr": "записывает", +} + + +def build_curated_answer_facts(bundle: EvidenceBundle) -> dict[str, Any]: + target = str(bundle.resolved_target or "").strip() + semantic_hints = _semantic_hints(bundle.code_chunks) + primary_chunks = [chunk for chunk in bundle.code_chunks if chunk.layer != "C4_SEMANTIC_ROLES"] + relations = _normalized_relations(bundle.relations) + target_relations = [relation for relation in relations if _is_target_relation(relation, target)] + + return { + "scenario": (bundle.resolved_sub_intent or "EXPLAIN").upper(), + "semantic_hints": semantic_hints, + "primary_chunk_count": len(primary_chunks), + "relation_count": len(relations), + "explain": _explain_facts(bundle, primary_chunks, target_relations), + "architecture": _architecture_facts(bundle, primary_chunks, target_relations), + "trace_flow": _trace_flow_facts(bundle, primary_chunks, target_relations), + } + + +def _explain_facts(bundle: EvidenceBundle, chunks: list[CodeChunkItem], relations: list[dict[str, Any]]) -> dict[str, Any]: + target = str(bundle.resolved_target or "").strip() + signatures = [_signature_payload(chunk) for chunk in chunks if chunk.layer == "C1_SYMBOL_CATALOG"] + target_signatures = [item for item in signatures if _is_target_symbol(item["name"], target)] + methods = _unique(item["name"] for item in target_signatures if item["kind"] == "method") + constructor_args = _unique( + arg + for item in target_signatures + if item["name"].endswith(".__init__") + for arg in item["args"] + if arg not in {"self", "cls"} + ) + calls = _unique( + _display_call_target(relation["target"]) + for relation in relations + if relation["edge_type"] in {"calls", "instantiates"} + ) + if not calls: + calls = _fallback_calls(chunks, target) + fields = _unique( + relation["target"].split(".", 1)[-1] + for relation in relations + if relation["edge_type"] in {"reads_attr", "writes_attr"} + ) + if not fields: + fields = _unique(field for chunk in chunks if _chunk_matches_target(chunk, target) for field in _FIELD_RE.findall(chunk.content or "")) + dependencies = _unique( + _display_dependency_target(relation["target"]) + for relation in relations + if relation["edge_type"] in {"imports", "instantiates"} + ) + required_files = _unique(chunk.path for chunk in chunks if _chunk_matches_target(chunk, target) and chunk.path) + required_symbols = _unique(item["name"] for item in target_signatures if item["name"]) or _unique([target] if target else bundle.target_symbol_candidates) + + fact_gaps: list[str] = [] + if not methods: + fact_gaps.append("Методы целевой сущности не подтверждены в извлеченных C0/C1 данных.") + if not calls: + fact_gaps.append("Конкретные вызовы целевой сущности не подтверждены в C2/C0.") + if not dependencies: + fact_gaps.append("Явные зависимости целевой сущности не подтверждены.") + + return { + "required_symbols": required_symbols[:8], + "required_methods": methods[:6], + "required_calls": calls[:6], + "required_fields": fields[:6], + "required_constructor_args": constructor_args[:6], + "required_dependencies": dependencies[:6], + "required_files": required_files[:4], + "fact_gaps": fact_gaps, + } + + +def _architecture_facts(bundle: EvidenceBundle, chunks: list[CodeChunkItem], relations: list[dict[str, Any]]) -> dict[str, Any]: + target = str(bundle.resolved_target or "").strip() + components = _unique( + ([target] if target else []) + + [_component_name(relation["source"]) for relation in relations] + + [_component_name(relation["target"]) for relation in relations] + + [_component_name(chunk.title) for chunk in chunks if _chunk_matches_target(chunk, target)] + ) + relation_rows = [ + { + "source": _component_name(relation["source"]), + "verb": relation["verb"], + "target": _component_name(relation["target"]), + "source_method": relation["source"], + "target_method": relation["target"], + "path": relation["path"], + "line_span": relation["line_span"], + "edge_type": relation["edge_type"], + } + for relation in relations + if _component_name(relation["source"]) and _component_name(relation["target"]) + ] + relation_rows = [row for row in relation_rows if row["source"] != row["target"]] + relation_verbs = _unique(row["verb"] for row in relation_rows if row["verb"]) + fact_gaps: list[str] = [] + if not relation_rows: + fact_gaps.append("Concrete code edges между компонентами не подтверждены.") + + return { + "required_components": components[:8], + "required_relations": relation_rows[:8], + "required_relation_verbs": relation_verbs[:6], + "required_creation_edges": [row for row in relation_rows if row["edge_type"] == "instantiates"][:4], + "required_call_edges": [row for row in relation_rows if row["edge_type"] == "calls"][:4], + "required_registration_edges": [row for row in relation_rows if row["edge_type"] == "imports"][:4], + "required_data_edges": [row for row in relation_rows if row["edge_type"] in {"reads_attr", "writes_attr"}][:4], + "fact_gaps": fact_gaps, + "forbidden_labels": list(_RETRIEVAL_LABELS), + } + + +def _trace_flow_facts(bundle: EvidenceBundle, chunks: list[CodeChunkItem], relations: list[dict[str, Any]]) -> dict[str, Any]: + target = str(bundle.resolved_target or "").strip() + flow_steps = [ + { + "step": index, + "source": relation["source"], + "verb": relation["verb"], + "target": relation["target"], + "path": relation["path"], + "line_span": relation["line_span"], + } + for index, relation in enumerate(sorted(relations, key=lambda item: (item["path"], item["sort_line"], item["source"], item["target"])), start=1) + ] + fact_gaps: list[str] = [] + if len(flow_steps) < 2: + fact_gaps.append("Полная последовательность шагов не подтверждена; виден только частичный flow.") + if not flow_steps: + fact_gaps.append("Конкретные sequence edges для flow не подтверждены.") + + return { + "required_flow_steps": flow_steps[:8], + "required_calls": _unique(_display_call_target(item["target"]) for item in flow_steps), + "required_sequence_edges": flow_steps[:8], + "required_files": _unique(chunk.path for chunk in chunks if _chunk_matches_target(chunk, target) and chunk.path)[:4], + "fact_gaps": fact_gaps, + } + + +def _semantic_hints(chunks: list[CodeChunkItem]) -> list[dict[str, Any]]: + hints: list[dict[str, Any]] = [] + for chunk in chunks: + if chunk.layer != "C4_SEMANTIC_ROLES": + continue + meta = dict(chunk.metadata or {}) + hints.append( + { + "symbol": meta.get("symbol_name") or chunk.title, + "role": meta.get("role"), + "path": chunk.path, + "confidence": meta.get("confidence"), + } + ) + return hints[:8] + + +def _normalized_relations(relations: list[dict[str, Any]]) -> list[dict[str, Any]]: + normalized: list[dict[str, Any]] = [] + for relation in relations: + metadata = dict(relation.get("metadata") or {}) + edge_type = str(metadata.get("edge_type") or relation.get("edge_type") or "").strip() + source = _clean_endpoint(str(metadata.get("src_qname") or relation.get("source") or "").strip()) + target = _clean_endpoint(str(metadata.get("dst_ref") or relation.get("target") or "").strip()) + if not edge_type or not source or not target: + continue + normalized.append( + { + "edge_type": edge_type, + "source": source, + "target": target, + "verb": _RELATION_VERBS.get(edge_type, edge_type), + "path": str(relation.get("path") or ""), + "line_span": _line_span(relation), + "sort_line": int(relation.get("start_line") or 0), + } + ) + return normalized + + +def _signature_payload(chunk: CodeChunkItem) -> dict[str, Any]: + meta = dict(chunk.metadata or {}) + signature = str(meta.get("signature") or chunk.content or "").strip() + match = _SIGNATURE_RE.search(signature) + args = [part.strip() for part in match.group("args").split(",") if part.strip()] if match else [] + return { + "name": _clean_endpoint(str(meta.get("qname") or chunk.title or "").strip()), + "kind": str(meta.get("kind") or "").strip(), + "args": args, + } + + +def _fallback_calls(chunks: list[CodeChunkItem], target: str) -> list[str]: + values: list[str] = [] + for chunk in chunks: + if not _chunk_matches_target(chunk, target): + continue + values.extend(_display_call_target(item) for item in _CALL_RE.findall(chunk.content or "")) + return _unique(values) + + +def _chunk_matches_target(chunk: CodeChunkItem, target: str) -> bool: + if not target: + return True + title = _clean_endpoint(chunk.title) + symbol = _clean_endpoint(str(dict(chunk.metadata or {}).get("qname") or "")) + return _is_target_symbol(title, target) or _is_target_symbol(symbol, target) or target.lower() in (chunk.content or "").lower() + + +def _is_target_relation(relation: dict[str, Any], target: str) -> bool: + if not target: + return True + return _is_target_symbol(relation["source"], target) or _component_name(relation["source"]) == target or _component_name(relation["target"]) == target + + +def _is_target_symbol(name: str, target: str) -> bool: + clean_name = _clean_endpoint(name) + clean_target = _clean_endpoint(target) + if not clean_target: + return True + return clean_name == clean_target or clean_name.startswith(f"{clean_target}.") + + +def _component_name(value: str) -> str: + clean = _clean_endpoint(value) + if not clean: + return "" + parts = clean.split(".") + if len(parts) <= 1: + return clean + if len(parts) == 2: + return clean if parts[1][:1].isupper() else parts[0] + return ".".join(parts[:-1]) + + +def _display_call_target(value: str) -> str: + clean = _clean_endpoint(value) + if not clean: + return "" + tail = clean.rsplit(".", 1)[-1] + return f"{tail}()" if tail and tail != clean else clean + + +def _display_dependency_target(value: str) -> str: + clean = _clean_endpoint(value) + if not clean: + return "" + return _component_name(clean) or clean + + +def _clean_endpoint(value: str) -> str: + clean = str(value or "").strip() + if not clean: + return "" + for label in _RETRIEVAL_LABELS: + clean = clean.replace(f".{label}", "") + clean = clean.replace(label, "") + return clean.strip(".: ") + + +def _line_span(item: dict[str, Any]) -> str: + start = item.get("start_line") + end = item.get("end_line") + if start is None and end is None: + return "?:?" + return f"{start or '?'}-{end or '?'}" + + +def _unique(values: Any) -> list[str]: + seen: set[str] = set() + result: list[str] = [] + for value in values: + text = str(value or "").strip() + if not text or text in seen: + continue + seen.add(text) + result.append(text) + return result diff --git a/src/app/modules/rag/code_qa_pipeline/answer_synthesis.py b/src/app/modules/rag/code_qa_pipeline/answer_synthesis.py index 4da24fb..0ce308a 100644 --- a/src/app/modules/rag/code_qa_pipeline/answer_synthesis.py +++ b/src/app/modules/rag/code_qa_pipeline/answer_synthesis.py @@ -2,6 +2,7 @@ from __future__ import annotations +from app.modules.rag.code_qa_pipeline.answer_fact_curator import build_curated_answer_facts from app.modules.rag.code_qa_pipeline.contracts import AnswerSynthesisInput, EvidenceBundle @@ -13,11 +14,16 @@ def build_answer_synthesis_input( scenario = bundle.resolved_sub_intent or "EXPLAIN" target = bundle.resolved_target sufficient = bundle.sufficient + curated = build_curated_answer_facts(bundle) + semantic_hints = list(curated.get("semantic_hints") or []) fast_lines = [ f"Scenario: {scenario}", f"Target: {target or 'none'}", f"Evidence chunks: {bundle.evidence_count}", + f"Primary chunks: {curated.get('primary_chunk_count', 0)}", + f"Semantic hints: {len(semantic_hints)}", + f"Relations: {curated.get('relation_count', 0)}", f"Sufficient: {sufficient}", ] if bundle.failure_reasons: @@ -25,18 +31,21 @@ def build_answer_synthesis_input( fast_context = "\n".join(fast_lines) deep_parts = [] - for i, c in enumerate(bundle.code_chunks[:30], 1): + primary_chunks = [chunk for chunk in bundle.code_chunks if scenario.upper() not in {"EXPLAIN", "ARCHITECTURE"} or chunk.layer != "C4_SEMANTIC_ROLES"] + for i, c in enumerate(primary_chunks[:30], 1): deep_parts.append(f"[{i}] {c.path}:{c.start_line or '?'}-{c.end_line or '?'}\n{c.content[:800]}") deep_context = "\n\n---\n\n".join(deep_parts) if deep_parts else "(no code chunks)" evidence_summary = [] - for c in bundle.code_chunks[:20]: + for c in primary_chunks[:20]: evidence_summary.append({ "layer": c.layer, "path": c.path, "title": c.title, "lines": f"{c.start_line or '?'}-{c.end_line or '?'}", }) + if semantic_hints: + evidence_summary.append({"kind": "semantic_hints", "count": len(semantic_hints)}) if bundle.entrypoints: evidence_summary.append({"kind": "entrypoints", "count": len(bundle.entrypoints)}) if bundle.test_evidence: @@ -45,6 +54,9 @@ def build_answer_synthesis_input( hints = list(bundle.failure_reasons) if bundle.failure_reasons else [] if not sufficient and bundle.retrieval_summary.get("missing_layers"): hints.append(f"Missing layers: {', '.join(bundle.retrieval_summary['missing_layers'])}") + scenario_key = scenario.lower() + scenario_facts = dict(curated.get(scenario_key) or {}) + hints.extend(list(scenario_facts.get("fact_gaps") or [])) return AnswerSynthesisInput( user_question=user_question, @@ -53,6 +65,8 @@ def build_answer_synthesis_input( fast_context=fast_context, deep_context=deep_context, evidence_summary=evidence_summary, + semantic_hints=semantic_hints, + curated_facts=curated, evidence_sufficient=sufficient, diagnostic_hints=hints, ) diff --git a/src/app/modules/rag/code_qa_pipeline/contracts.py b/src/app/modules/rag/code_qa_pipeline/contracts.py index 0ffe729..0fa3253 100644 --- a/src/app/modules/rag/code_qa_pipeline/contracts.py +++ b/src/app/modules/rag/code_qa_pipeline/contracts.py @@ -98,6 +98,7 @@ class RetrievalResult(BaseModel): file_candidates: list[str] = Field(default_factory=list) code_chunks: list[CodeChunkItem] = Field(default_factory=list) relations: list[dict[str, Any]] = Field(default_factory=list) + semantic_hints: list[dict[str, Any]] = Field(default_factory=list) entrypoints: list[dict[str, Any]] = Field(default_factory=list) test_candidates: list[dict[str, Any]] = Field(default_factory=list) layer_outcomes: list[LayerOutcome] = Field(default_factory=list) @@ -138,6 +139,8 @@ class AnswerSynthesisInput(BaseModel): fast_context: str = "" deep_context: str = "" evidence_summary: list[dict[str, Any]] = Field(default_factory=list) + semantic_hints: list[dict[str, Any]] = Field(default_factory=list) + curated_facts: dict[str, Any] = Field(default_factory=dict) evidence_sufficient: bool = False diagnostic_hints: list[str] = Field(default_factory=list) diff --git a/src/app/modules/rag/code_qa_pipeline/evidence_bundle_builder.py b/src/app/modules/rag/code_qa_pipeline/evidence_bundle_builder.py index 71b87af..7c8841d 100644 --- a/src/app/modules/rag/code_qa_pipeline/evidence_bundle_builder.py +++ b/src/app/modules/rag/code_qa_pipeline/evidence_bundle_builder.py @@ -28,6 +28,7 @@ def build_evidence_bundle( summary = { "chunk_count": len(retrieval_result.code_chunks), "relation_count": len(retrieval_result.relations), + "semantic_hint_count": len(retrieval_result.semantic_hints), "entrypoint_count": len(retrieval_result.entrypoints), "test_candidate_count": len(retrieval_result.test_candidates), "layers_with_hits": [ diff --git a/src/app/modules/rag/code_qa_pipeline/retrieval_result_builder.py b/src/app/modules/rag/code_qa_pipeline/retrieval_result_builder.py index 75d892f..fb19c1f 100644 --- a/src/app/modules/rag/code_qa_pipeline/retrieval_result_builder.py +++ b/src/app/modules/rag/code_qa_pipeline/retrieval_result_builder.py @@ -2,13 +2,14 @@ from __future__ import annotations -from app.modules.rag.code_qa_pipeline.contracts import ( - CodeChunkItem, - LayerOutcome, - RetrievalResult, -) +import re + +from app.modules.rag.code_qa_pipeline.contracts import CodeChunkItem, LayerOutcome, RetrievalResult from app.modules.rag.retrieval.test_filter import is_test_path +_ROUTE_RE = re.compile(r'@[\w\.]+\.(get|post|put|delete|patch|options|head)\(\s*["\']([^"\']+)["\']') +_DEF_RE = re.compile(r"async\s+def\s+(\w+)|def\s+(\w+)") + def build_retrieval_result( raw_rows: list[dict], @@ -21,52 +22,210 @@ def build_retrieval_result( layers_seen: set[str] = set() code_chunks: list[CodeChunkItem] = [] relations: list[dict] = [] - entrypoints: list[dict] = [] + semantic_hints: list[dict] = [] + entrypoint_rows: list[CodeChunkItem] = [] test_candidates: list[dict] = [] file_candidates: list[str] = [] target_symbols: list[str] = [] for row in raw_rows: - layer = str(row.get("layer") or "") - path = str(row.get("path") or "") + chunk = _to_chunk(row) + layer = chunk.layer + path = chunk.path if layer: layers_seen.add(layer) if path and path not in file_candidates: file_candidates.append(path) - - chunk = CodeChunkItem( - layer=layer, - path=path, - title=str(row.get("title") or ""), - content=str(row.get("content") or ""), - start_line=row.get("span_start"), - end_line=row.get("span_end"), - metadata=dict(row.get("metadata") or {}), - ) code_chunks.append(chunk) if layer == "C1_SYMBOL_CATALOG": - title = str(row.get("title") or "").strip() + title = chunk.title.strip() if title and title not in target_symbols: target_symbols.append(title) - elif layer == "C2_DEPENDENCY_GRAPH": - relations.append({"path": path, "metadata": chunk.metadata, "content": chunk.content[:500]}) - elif layer == "C3_ENTRYPOINTS": - entrypoints.append({"path": path, "title": chunk.title, "metadata": chunk.metadata}) - elif is_test_path(path): + continue + if layer == "C2_DEPENDENCY_GRAPH": + relations.append(_relation_payload(chunk)) + continue + if layer == "C4_SEMANTIC_ROLES": + semantic_hints.append(_semantic_hint_payload(chunk)) + continue + if layer == "C3_ENTRYPOINTS": + entrypoint_rows.append(chunk) + continue + if is_test_path(path): test_candidates.append({"path": path, "title": chunk.title, "content": chunk.content[:300]}) + entrypoints = _normalize_entrypoints(entrypoint_rows, code_chunks) executed = list(report.get("executed_layers") or []) missing_layers = [lid for lid in executed if lid not in layers_seen] + layer_outcomes = _layer_outcomes(raw_rows, executed, layers_seen, report) + + resolved = str(sym.get("resolved_symbol") or "").strip() or None + status = str(sym.get("status") or "not_requested") + + return RetrievalResult( + target_symbol_candidates=target_symbols, + resolved_symbol=resolved, + symbol_resolution_status=status, + file_candidates=file_candidates, + code_chunks=code_chunks, + relations=relations, + semantic_hints=semantic_hints, + entrypoints=entrypoints, + test_candidates=test_candidates, + layer_outcomes=layer_outcomes, + missing_layers=missing_layers, + raw_rows=raw_rows, + retrieval_report=report, + ) + + +def _to_chunk(row: dict) -> CodeChunkItem: + return CodeChunkItem( + layer=str(row.get("layer") or ""), + path=str(row.get("path") or ""), + title=str(row.get("title") or ""), + content=str(row.get("content") or ""), + start_line=row.get("span_start"), + end_line=row.get("span_end"), + metadata=dict(row.get("metadata") or {}), + ) + + +def _normalize_entrypoints(entrypoint_rows: list[CodeChunkItem], code_chunks: list[CodeChunkItem]) -> list[dict]: + chunks_by_path: dict[str, list[CodeChunkItem]] = {} + for chunk in code_chunks: + chunks_by_path.setdefault(chunk.path, []).append(chunk) + + normalized: list[dict] = [] + seen: set[tuple[str, str, str, int | None, int | None]] = set() + for chunk in entrypoint_rows: + item = _entrypoint_payload(chunk, chunks_by_path.get(chunk.path, [])) + key = ( + str(item.get("http_method") or ""), + str(item.get("route_path") or ""), + str(item.get("path") or ""), + chunk.start_line, + chunk.end_line, + ) + if key in seen: + continue + seen.add(key) + normalized.append(item) + return sorted(normalized, key=_entrypoint_sort_key) + + +def _relation_payload(chunk: CodeChunkItem) -> dict: + metadata = dict(chunk.metadata or {}) + edge_type = str(metadata.get("edge_type") or "").strip() + src_qname = str(metadata.get("src_qname") or "").strip() + dst_ref = str(metadata.get("dst_ref") or "").strip() + return { + "path": chunk.path, + "start_line": chunk.start_line, + "end_line": chunk.end_line, + "edge_type": edge_type, + "source": src_qname, + "target": dst_ref, + "source_component": _component_name(src_qname), + "target_component": _component_name(dst_ref), + "has_retrieval_label": "dataflow_slice" in dst_ref or "dataflow_slice" in src_qname, + "metadata": metadata, + "content": chunk.content[:500], + } + + +def _semantic_hint_payload(chunk: CodeChunkItem) -> dict: + metadata = dict(chunk.metadata or {}) + return { + "path": chunk.path, + "title": chunk.title, + "symbol": metadata.get("symbol_name") or chunk.title, + "role": metadata.get("role"), + "confidence": metadata.get("confidence"), + "content": chunk.content[:300], + } + + +def _component_name(value: str) -> str: + cleaned = str(value or "").replace(".dataflow_slice", "").strip(". ") + if "." not in cleaned: + return cleaned + head, tail = cleaned.rsplit(".", 1) + return head if tail and not tail[:1].isupper() else cleaned + + +def _entrypoint_payload(chunk: CodeChunkItem, siblings: list[CodeChunkItem]) -> dict: + methods = [str(item).strip().upper() for item in list(dict(chunk.metadata).get("lang_payload", {}).get("methods", [])) if str(item).strip()] + method = methods[0] if methods else "" + route_path = _infer_route_path(chunk, siblings) + handler_symbol = _infer_handler_symbol(chunk, siblings) + return { + "path": chunk.path, + "title": chunk.title, + "start_line": chunk.start_line, + "end_line": chunk.end_line, + "http_method": method, + "route_path": route_path, + "handler_symbol": handler_symbol, + "handler_symbol_id": dict(chunk.metadata).get("handler_symbol_id"), + "route_or_command": dict(chunk.metadata).get("route_or_command"), + "metadata": chunk.metadata, + } + + +def _infer_route_path(chunk: CodeChunkItem, siblings: list[CodeChunkItem]) -> str: + for candidate in siblings: + if candidate.layer != "C0_SOURCE_CHUNKS": + continue + match = _ROUTE_RE.search(_window_text(candidate, chunk.start_line)) + if match: + return match.group(2).strip() + return "" + + +def _infer_handler_symbol(chunk: CodeChunkItem, siblings: list[CodeChunkItem]) -> str: + for candidate in siblings: + if candidate.layer != "C0_SOURCE_CHUNKS": + continue + match = _DEF_RE.search(_window_text(candidate, chunk.start_line, before=2, after=12)) + if match: + return match.group(1) or match.group(2) or "" + return "" + + +def _window_text(chunk: CodeChunkItem, target_line: int | None, *, before: int = 6, after: int = 8) -> str: + text = chunk.content or "" + if not text or not target_line or not chunk.start_line: + return text + lines = text.splitlines() + offset = max(0, target_line - chunk.start_line - before) + end = min(len(lines), target_line - chunk.start_line + after) + if offset >= end: + return text + return "\n".join(lines[offset:end]) + + +def _entrypoint_sort_key(item: dict) -> tuple[int, int, str, str, int]: + route_path = str(item.get("route_path") or "") + method = str(item.get("http_method") or "") + score = 0 + if route_path: + score += 3 + if route_path and route_path != "/": + score += 3 + if method: + score += 1 + return (-score, len(route_path or "zzzz"), method, str(item.get("path") or ""), int(item.get("start_line") or 0)) + + +def _layer_outcomes(raw_rows: list[dict], executed: list[str], layers_seen: set[str], report: dict) -> list[LayerOutcome]: layer_outcomes = [ LayerOutcome( layer_id=layer_id, hit_count=sum(1 for r in raw_rows if str(r.get("layer") or "") == layer_id), empty=layer_id not in layers_seen, - fallback_used=bool( - (report.get("fallback") or {}).get("used") - and report.get("retrieval_mode_by_layer", {}).get(layer_id) - ), + fallback_used=bool((report.get("fallback") or {}).get("used") and report.get("retrieval_mode_by_layer", {}).get(layer_id)), ) for layer_id in executed ] @@ -80,21 +239,4 @@ def build_retrieval_result( fallback_used=False, ) ) - - resolved = str(sym.get("resolved_symbol") or "").strip() or None - status = str(sym.get("status") or "not_requested") - - return RetrievalResult( - target_symbol_candidates=target_symbols, - resolved_symbol=resolved, - symbol_resolution_status=status, - file_candidates=file_candidates, - code_chunks=code_chunks, - relations=relations, - entrypoints=entrypoints, - test_candidates=test_candidates, - layer_outcomes=layer_outcomes, - missing_layers=missing_layers, - raw_rows=raw_rows, - retrieval_report=report, - ) + return layer_outcomes diff --git a/src/app/modules/shared/gigachat/settings.py b/src/app/modules/shared/gigachat/settings.py index 026515c..654a9f6 100644 --- a/src/app/modules/shared/gigachat/settings.py +++ b/src/app/modules/shared/gigachat/settings.py @@ -20,6 +20,6 @@ class GigaChatSettings: scope=os.getenv("GIGACHAT_SCOPE", "GIGACHAT_API_PERS"), credentials=os.getenv("GIGACHAT_TOKEN", "").strip(), ssl_verify=os.getenv("GIGACHAT_SSL_VERIFY", "true").lower() in {"1", "true", "yes"}, - model=os.getenv("GIGACHAT_MODEL", "GigaChat"), + model=os.getenv("GIGACHAT_MODEL", "GigaChat-Pro"), embedding_model=os.getenv("GIGACHAT_EMBEDDING_MODEL", "Embeddings"), ) diff --git a/tests/pipeline_setup/suite_02_pipeline/pipeline_intent_rag/test_code_qa_answer_boundary.py b/tests/pipeline_setup/suite_02_pipeline/pipeline_intent_rag/test_code_qa_answer_boundary.py new file mode 100644 index 0000000..13e6709 --- /dev/null +++ b/tests/pipeline_setup/suite_02_pipeline/pipeline_intent_rag/test_code_qa_answer_boundary.py @@ -0,0 +1,323 @@ +from __future__ import annotations + +import json + +from app.modules.agent.code_qa_runtime.post_gate import CodeQaPostEvidenceGate +from app.modules.agent.code_qa_runtime.prompt_payload_builder import CodeQaPromptPayloadBuilder +from app.modules.rag.code_qa_pipeline.answer_synthesis import build_answer_synthesis_input +from app.modules.rag.code_qa_pipeline.contracts import CodeChunkItem, EvidenceBundle +from app.modules.rag.code_qa_pipeline.retrieval_result_builder import build_retrieval_result + + +def test_retrieval_result_separates_semantic_hints_and_relations() -> None: + raw = [ + { + "layer": "C2_DEPENDENCY_GRAPH", + "path": "src/runtime.py", + "content": "RuntimeManager calls TraceService", + "span_start": 10, + "span_end": 10, + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.record"}, + }, + { + "layer": "C4_SEMANTIC_ROLES", + "path": "src/runtime.py", + "title": "RuntimeManager", + "content": "role: orchestrator", + "span_start": 1, + "span_end": 20, + "metadata": {"symbol_name": "RuntimeManager", "role": "orchestrator", "confidence": 0.7}, + }, + ] + result = build_retrieval_result(raw, {"executed_layers": ["C2_DEPENDENCY_GRAPH", "C4_SEMANTIC_ROLES"]}, {"status": "resolved"}) + assert result.relations[0]["edge_type"] == "calls" + assert result.relations[0]["source"] == "RuntimeManager.start" + assert result.semantic_hints[0]["role"] == "orchestrator" + + +def test_answer_synthesis_curates_explain_facts_and_demotes_c4() -> None: + bundle = EvidenceBundle( + resolved_sub_intent="EXPLAIN", + resolved_target="RuntimeManager", + target_type="symbol", + evidence_count=4, + sufficient=True, + code_chunks=[ + CodeChunkItem( + layer="C1_SYMBOL_CATALOG", + path="src/runtime.py", + title="RuntimeManager.__init__", + content="__init__(self, tracer, registry)", + start_line=1, + end_line=3, + metadata={"qname": "RuntimeManager.__init__", "kind": "method", "signature": "__init__(self, tracer, registry)"}, + ), + CodeChunkItem( + layer="C0_SOURCE_CHUNKS", + path="src/runtime.py", + title="", + content="self.tracer = tracer\nself.registry = registry\nself.tracer.record()\n", + start_line=1, + end_line=4, + metadata={}, + ), + CodeChunkItem( + layer="C4_SEMANTIC_ROLES", + path="src/runtime.py", + title="RuntimeManager", + content="role: orchestrator", + start_line=1, + end_line=4, + metadata={"symbol_name": "RuntimeManager", "role": "orchestrator"}, + ), + ], + relations=[ + { + "path": "src/runtime.py", + "start_line": 3, + "end_line": 3, + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.__init__", "dst_ref": "self.tracer.record"}, + } + ], + ) + synthesis = build_answer_synthesis_input("Explain RuntimeManager", bundle) + explain = synthesis.curated_facts["explain"] + assert "RuntimeManager.__init__" in explain["required_methods"] + assert "tracer" in explain["required_constructor_args"] + assert "record" in synthesis.deep_context or "self.tracer.record" in json.dumps(explain) + assert "orchestrator" not in synthesis.deep_context + assert synthesis.semantic_hints[0]["role"] == "orchestrator" + + +def test_prompt_payload_builder_adds_explain_constraints() -> None: + bundle = EvidenceBundle(resolved_sub_intent="EXPLAIN", resolved_target="RuntimeManager") + synthesis = build_answer_synthesis_input( + "Explain RuntimeManager", + EvidenceBundle( + resolved_sub_intent="EXPLAIN", + resolved_target="RuntimeManager", + code_chunks=[ + CodeChunkItem( + layer="C1_SYMBOL_CATALOG", + path="src/runtime.py", + title="RuntimeManager.start", + content="start(self)", + metadata={"qname": "RuntimeManager.start", "kind": "method", "signature": "start(self)"}, + ) + ], + evidence_count=1, + ), + ) + payload = json.loads( + CodeQaPromptPayloadBuilder().build( + user_query="Explain RuntimeManager", + synthesis_input=synthesis, + evidence_pack=bundle, + answer_mode="normal", + ) + ) + assert "must_mention_methods" in payload + assert "RuntimeManager.start" in payload["must_mention_methods"] + assert payload["must_not_infer_missing_details"] is True + + +def test_prompt_payload_builder_adds_trace_flow_constraints() -> None: + synthesis = build_answer_synthesis_input( + "Trace RuntimeManager", + EvidenceBundle( + resolved_sub_intent="TRACE_FLOW", + resolved_target="RuntimeManager", + relations=[ + { + "path": "src/runtime.py", + "start_line": 10, + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.record"}, + }, + { + "path": "src/runtime.py", + "start_line": 11, + "metadata": {"edge_type": "calls", "src_qname": "TraceService.record", "dst_ref": "Registry.register"}, + }, + ], + evidence_count=2, + ), + ) + payload = json.loads( + CodeQaPromptPayloadBuilder().build( + user_query="Trace RuntimeManager", + synthesis_input=synthesis, + evidence_pack=EvidenceBundle(resolved_sub_intent="TRACE_FLOW", resolved_target="RuntimeManager"), + answer_mode="normal", + ) + ) + assert payload["must_mention_flow_steps"] + assert payload["must_avoid_overclaiming_full_flow"] is True + + +def test_post_gate_rejects_vague_explain_without_concrete_facts() -> None: + bundle = EvidenceBundle( + resolved_sub_intent="EXPLAIN", + resolved_target="RuntimeManager", + evidence_count=3, + code_chunks=[ + CodeChunkItem( + layer="C1_SYMBOL_CATALOG", + path="src/runtime.py", + title="RuntimeManager.start", + content="start(self)", + metadata={"qname": "RuntimeManager.start", "kind": "method", "signature": "start(self)"}, + ) + ], + relations=[ + { + "path": "src/runtime.py", + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.record"}, + } + ], + ) + result = CodeQaPostEvidenceGate().validate( + answer="RuntimeManager имеет responsibilities и управляет системой.", + answer_mode="normal", + degraded_message="", + sub_intent="EXPLAIN", + user_query="Explain RuntimeManager", + evidence_pack=bundle, + ) + assert result.passed is False + assert "missing_concrete_methods" in result.reasons + assert "too_vague_for_explain" in result.reasons + + +def test_post_gate_accepts_explain_with_method_alias_and_call() -> None: + bundle = EvidenceBundle( + resolved_sub_intent="EXPLAIN", + resolved_target="RuntimeManager", + evidence_count=3, + code_chunks=[ + CodeChunkItem( + layer="C1_SYMBOL_CATALOG", + path="src/runtime.py", + title="RuntimeManager.start", + content="start(self)", + metadata={"qname": "RuntimeManager.start", "kind": "method", "signature": "start(self)"}, + ) + ], + relations=[ + { + "path": "src/runtime.py", + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.record"}, + } + ], + ) + result = CodeQaPostEvidenceGate().validate( + answer="RuntimeManager запускает работу через метод start(), а затем вызывает record() у TraceService.", + answer_mode="normal", + degraded_message="", + sub_intent="EXPLAIN", + user_query="Explain RuntimeManager", + evidence_pack=bundle, + ) + assert result.passed is True + + +def test_post_gate_requires_architecture_relations() -> None: + bundle = EvidenceBundle( + resolved_sub_intent="ARCHITECTURE", + resolved_target="RuntimeManager", + evidence_count=3, + code_chunks=[ + CodeChunkItem(layer="C1_SYMBOL_CATALOG", path="src/runtime.py", title="RuntimeManager", content="", metadata={"qname": "RuntimeManager", "kind": "class"}), + CodeChunkItem(layer="C4_SEMANTIC_ROLES", path="src/runtime.py", title="RuntimeManager", content="", metadata={"symbol_name": "RuntimeManager", "role": "orchestrator"}), + ], + relations=[ + { + "path": "src/runtime.py", + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.record"}, + } + ], + ) + gate = CodeQaPostEvidenceGate() + vague = gate.validate( + answer="RuntimeManager и TraceService образуют центральный компонент runtime.", + answer_mode="normal", + degraded_message="", + sub_intent="ARCHITECTURE", + user_query="Architecture of RuntimeManager", + evidence_pack=bundle, + ) + concrete = gate.validate( + answer="RuntimeManager.start вызывает TraceService.record в src/runtime.py.", + answer_mode="normal", + degraded_message="", + sub_intent="ARCHITECTURE", + user_query="Architecture of RuntimeManager", + evidence_pack=bundle, + ) + assert vague.passed is False + assert "missing_relation_verbs" in vague.reasons or "missing_concrete_relations" in vague.reasons + assert concrete.passed is True + + +def test_post_gate_rejects_architecture_with_retrieval_labels() -> None: + bundle = EvidenceBundle( + resolved_sub_intent="ARCHITECTURE", + resolved_target="RuntimeManager", + evidence_count=2, + relations=[ + { + "path": "src/runtime.py", + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.dataflow_slice"}, + } + ], + ) + result = CodeQaPostEvidenceGate().validate( + answer="RuntimeManager связан с dataflow_slice и строит вокруг него архитектуру.", + answer_mode="normal", + degraded_message="", + sub_intent="ARCHITECTURE", + user_query="Architecture of RuntimeManager", + evidence_pack=bundle, + ) + assert result.passed is False + assert "contains_retrieval_artifacts" in result.reasons + + +def test_post_gate_trace_flow_requires_sequence_and_blocks_overclaim() -> None: + bundle = EvidenceBundle( + resolved_sub_intent="TRACE_FLOW", + resolved_target="RuntimeManager", + evidence_count=3, + relations=[ + { + "path": "src/runtime.py", + "start_line": 10, + "metadata": {"edge_type": "calls", "src_qname": "RuntimeManager.start", "dst_ref": "TraceService.record"}, + }, + { + "path": "src/runtime.py", + "start_line": 11, + "metadata": {"edge_type": "calls", "src_qname": "TraceService.record", "dst_ref": "Registry.register"}, + }, + ], + ) + gate = CodeQaPostEvidenceGate() + vague = gate.validate( + answer="RuntimeManager инициализирует службы и полностью восстанавливается.", + answer_mode="normal", + degraded_message="", + sub_intent="TRACE_FLOW", + user_query="Trace RuntimeManager", + evidence_pack=bundle, + ) + concrete = gate.validate( + answer="Сначала RuntimeManager.start вызывает TraceService.record, затем TraceService.record вызывает Registry.register.", + answer_mode="normal", + degraded_message="", + sub_intent="TRACE_FLOW", + user_query="Trace RuntimeManager", + evidence_pack=bundle, + ) + assert vague.passed is False + assert "missing_flow_steps" in vague.reasons or "too_vague_for_trace_flow" in vague.reasons + assert "overclaims_trace_completeness" in vague.reasons + assert concrete.passed is True diff --git a/tests/pipeline_setup_v2/core/artifacts.py b/tests/pipeline_setup_v2/core/artifacts.py index 2edc195..06b07a9 100644 --- a/tests/pipeline_setup_v2/core/artifacts.py +++ b/tests/pipeline_setup_v2/core/artifacts.py @@ -65,8 +65,8 @@ class SummaryComposer: "", f"Passed: {passed}/{len(results)}", "", - "| File | Case | Query | Expected sub-intent | Intent | Actual sub-intent | RAG layers | Pass |", - "|------|------|-------|---------------------|--------|-------------------|------------|------|", + "| File | Case | Query | Expected sub-intent | Intent | Actual sub-intent | RAG layers | Tokens | Pass |", + "|------|------|-------|---------------------|--------|-------------------|------------|--------|------|", ] lines.extend(self._result_rows(results)) lines.extend(self._failure_section(results)) @@ -80,7 +80,7 @@ class SummaryComposer: rows.append( f"| {item.case.source_file.name} | {item.case.case_id} | {self._table_text(item.case.query)} | " f"{item.case.expectations.router.sub_intent or '—'} | {actual.get('intent') or '—'} | " - f"{actual.get('sub_intent') or '—'} | {self._rag_layers_text(item)} | {'✓' if item.passed else '✗'} |" + f"{actual.get('sub_intent') or '—'} | {self._rag_layers_text(item)} | {self._token_text(item)} | {'✓' if item.passed else '✗'} |" ) return rows @@ -142,3 +142,10 @@ class SummaryComposer: return "—" parts = [f"{layer}:{counts[layer]}" for layer in sorted(counts)] return self._table_text(", ".join(parts), limit=120) + + def _token_text(self, item: V2CaseResult) -> str: + diagnostics = dict(item.details.get("diagnostics") or {}) + prompt = dict(diagnostics.get("prompt") or {}) + stats = dict(prompt.get("prompt_stats") or {}) + value = stats.get("tokens_in_estimate") + return str(value) if value is not None else "—" diff --git a/tests/pipeline_setup_v2/core/test_validators.py b/tests/pipeline_setup_v2/core/test_validators.py index bd5cb11..886f0ca 100644 --- a/tests/pipeline_setup_v2/core/test_validators.py +++ b/tests/pipeline_setup_v2/core/test_validators.py @@ -2,6 +2,7 @@ from __future__ import annotations from pathlib import Path +from tests.pipeline_setup_v2.core.artifacts import SummaryComposer from tests.pipeline_setup_v2.core.models import CaseExpectations, LlmExpectation, RetrievalExpectation, RouterExpectation, V2Case from tests.pipeline_setup_v2.core.validators import CaseValidator @@ -108,3 +109,29 @@ def test_llm_contains_and_excludes_checks() -> None: mismatches = CaseValidator().validate(case, actual, {}) assert mismatches == [] + + +def test_summary_includes_token_usage_column() -> None: + case = V2Case( + case_id="llm-quality", + runner="runtime", + mode="full_chain", + query="Где health endpoint?", + source_file=Path("cases.yaml"), + ) + result_text = SummaryComposer().compose([ + type( + "Result", + (), + { + "case": case, + "actual": {"intent": "CODE_QA", "sub_intent": "FIND_ENTRYPOINTS"}, + "details": {"diagnostics": {"prompt": {"prompt_stats": {"tokens_in_estimate": 654}}}, "rag_rows": []}, + "passed": True, + "mismatches": [], + }, + )() + ]) + + assert "Tokens" in result_text + assert "654" in result_text diff --git a/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml b/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml new file mode 100644 index 0000000..7a306d5 --- /dev/null +++ b/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml @@ -0,0 +1,121 @@ +defaults: + runner: runtime + mode: full_chain + input: + rag_session_id: "7d11da21-faa0-4cea-aede-aeabe069164c" + +cases: + - id: plba-v3-open-file-runtime + query: "Открой файл src/app_runtime/core/runtime.py" + notes: "Representative OPEN_FILE case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: OPEN_FILE + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + path_scope_contains: ["src/app_runtime/core/runtime.py"] + layers_include: ["C0_SOURCE_CHUNKS"] + llm: + non_empty: true + + - id: plba-v3-explain-runtime-manager + query: "Объясни как работает класс RuntimeManager" + notes: "Representative EXPLAIN case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: EXPLAIN + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + symbol_candidates_contain: ["RuntimeManager"] + layers_include: ["C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", "C2_DEPENDENCY_GRAPH"] + llm: + non_empty: true + excludes: ["ряд аргументов", "основные службы"] + + - id: plba-v3-explain-local-http-channel + query: "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?" + notes: "Representative EXPLAIN_LOCAL case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: EXPLAIN_LOCAL + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + path_scope_contains: ["src/app_runtime/control/http_channel.py"] + symbol_candidates_contain: ["HttpControlChannel"] + layers_include: ["C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", "C2_DEPENDENCY_GRAPH"] + llm: + non_empty: true + + - id: plba-v3-find-tests-runtime-manager + query: "Где тесты для RuntimeManager?" + notes: "Representative FIND_TESTS case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: FIND_TESTS + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + symbol_candidates_contain: ["RuntimeManager"] + layers_include: ["C1_SYMBOL_CATALOG", "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS"] + llm: + non_empty: true + + - id: plba-v3-find-entrypoints-health-endpoint + query: "Где health endpoint?" + notes: "Representative FIND_ENTRYPOINTS case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: FIND_ENTRYPOINTS + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + layers_include: ["C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS"] + llm: + non_empty: true + contains_all: ["GET /health"] + excludes: ["нет явных неподтвержденных кандидатов", "кандидаты на health-endpoint"] + + - id: plba-v3-trace-flow-runtime-start + query: "Покажи поток выполнения при запуске RuntimeManager" + notes: "Representative TRACE_FLOW case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: TRACE_FLOW + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + symbol_candidates_contain: ["RuntimeManager"] + layers_include: ["C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS"] + llm: + non_empty: true + + - id: plba-v3-architecture-runtime-manager + query: "Какие компоненты участвуют в RuntimeManager?" + notes: "Representative ARCHITECTURE case copied from full_chain_plba_code_subintents_v2.yaml" + expected: + router: + intent: CODE_QA + sub_intent: ARCHITECTURE + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + symbol_candidates_contain: ["RuntimeManager"] + layers_include: ["C4_SEMANTIC_ROLES", "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS"] + llm: + non_empty: true diff --git a/tests/pipeline_setup_v3/core/artifacts.py b/tests/pipeline_setup_v3/core/artifacts.py index 17b90cf..7ace880 100644 --- a/tests/pipeline_setup_v3/core/artifacts.py +++ b/tests/pipeline_setup_v3/core/artifacts.py @@ -66,8 +66,8 @@ class SummaryComposer: "", f"Passed: {passed}/{len(results)}", "", - "| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass |", - "|------|------|------|-------|-------------------|------------|------|", + "| File | Case | Mode | Query | Actual sub-intent | RAG layers | Tokens | Pass |", + "|------|------|------|-------|-------------------|------------|--------|------|", ] lines.extend(self._rows(results)) failures = [item for item in results if not item.passed] @@ -84,7 +84,7 @@ class SummaryComposer: rows.append( f"| {item.case.source_file.name} | {item.case.case_id} | {item.case.mode} | " f"{self._cell(item.case.query)} | {item.actual.get('sub_intent') or '—'} | " - f"{self._layer_text(item.details)} | {'✓' if item.passed else '✗'} |" + f"{self._layer_text(item.details)} | {self._token_text(item.details)} | {'✓' if item.passed else '✗'} |" ) return rows @@ -104,6 +104,16 @@ class SummaryComposer: return compact return compact[: limit - 1].rstrip() + "…" + def _token_text(self, details: dict) -> str: + token_usage = dict(details.get("token_usage") or {}) + direct = token_usage.get("tokens_in_estimate") + if direct is not None: + return str(direct) + prompt = dict(details.get("diagnostics", {}).get("prompt") or {}) + stats = dict(prompt.get("prompt_stats") or {}) + value = stats.get("tokens_in_estimate") + return str(value) if value is not None else "—" + def _llm_section(self, results: list[V3CaseResult]) -> list[str]: llm_results = [item for item in results if str(item.actual.get("llm_answer") or "").strip()] if not llm_results: diff --git a/tests/pipeline_setup_v3/core/test_validators.py b/tests/pipeline_setup_v3/core/test_validators.py index 4488c88..ad6cac7 100644 --- a/tests/pipeline_setup_v3/core/test_validators.py +++ b/tests/pipeline_setup_v3/core/test_validators.py @@ -2,6 +2,7 @@ from __future__ import annotations from pathlib import Path +from tests.pipeline_setup_v3.core.artifacts import SummaryComposer from tests.pipeline_setup_v3.core.models import CaseExpectations, LlmExpectation, RetrievalExpectation, RouterExpectation, V3Case from tests.pipeline_setup_v3.core.validators import CaseValidator @@ -66,3 +67,29 @@ def test_llm_contains_and_excludes_checks() -> None: } assert CaseValidator().validate(case, actual, {}) == [] + + +def test_summary_includes_token_usage_column() -> None: + case = V3Case( + case_id="llm-quality", + runner="agent_runtime", + mode="full_chain", + query="Где health endpoint?", + source_file=Path("cases.yaml"), + ) + result_text = SummaryComposer().compose([ + type( + "Result", + (), + { + "case": case, + "actual": {"sub_intent": "FIND_ENTRYPOINTS"}, + "details": {"token_usage": {"tokens_in_estimate": 321}, "rag_rows": []}, + "passed": True, + "mismatches": [], + }, + )() + ]) + + assert "Tokens" in result_text + assert "321" in result_text diff --git a/tests/pipeline_setup_v3/runtime/agent_runtime_adapter.py b/tests/pipeline_setup_v3/runtime/agent_runtime_adapter.py index 8bf35f8..9ddd33d 100644 --- a/tests/pipeline_setup_v3/runtime/agent_runtime_adapter.py +++ b/tests/pipeline_setup_v3/runtime/agent_runtime_adapter.py @@ -1,5 +1,7 @@ from __future__ import annotations +import math + from app.modules.agent.code_qa_runtime import CodeQaRuntimeExecutor from app.modules.agent.code_qa_runtime.repo_context import CodeQaRepoContextFactory from app.modules.agent.code_qa_runtime.retrieval_adapter import CodeQaRetrievalAdapter @@ -87,6 +89,7 @@ class AgentRuntimeAdapter: "diagnostics": result.diagnostics.model_dump(mode="json"), "rag_rows": list(result.retrieval_result.raw_rows) if result.retrieval_result else [], "validation": result.validation.model_dump(mode="json"), + "token_usage": _token_usage(result), "steps": list(result.runtime_trace), } return ExecutionPayload(actual=actual, details=details) @@ -169,3 +172,15 @@ def _answer_status(answer_mode: str, llm_used: bool) -> str: if answer_mode == "normal" and llm_used: return "answered" return answer_mode + + +def _token_usage(result) -> dict: + draft = result.draft_answer + if draft is None: + return {} + system_prompt = PromptLoader().load(draft.prompt_name) + tokens_in_estimate = max(1, int(math.ceil((len(system_prompt or "") + len(draft.prompt_payload or "")) / 4))) + return { + "prompt_name": draft.prompt_name, + "tokens_in_estimate": tokens_in_estimate, + } diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339.zip b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339.zip new file mode 100644 index 0000000000000000000000000000000000000000..af85126f346646eca9b84a069c7cbb8745275e80 GIT binary patch literal 137913 zcmbrl1#n|awq|W+W~MSTGc#LunaWURW@eX}nVH#TmzkNFnVFf{<9oYj`c1!{nLpxJ ze0fr#khY|ZqZ6UER{~@}!O(#Ix=CbMYW;oZp9dr$A|Pf)W_CsvCT1NbE*2IRE(Rx8 zSRi1qdte}-zh9)H3=aeeaav;r`8EEU0e@G60)qN))o{M5>FCG_i70$mXQ0>lx5EFo zx=CMk4Rp~BOmy{iujFJ^uMky306riwSfCV0xWIPANd8aZ*dZWM#Kb}Xa>+qBq66{o zJt0V#aubvDGPIOKQu8#FBMdU*GGj9GM!JUjSCJcD4#Lap!ax8SNGKp169Lt)Z=C-% z{`Kkk{%tMH{=-@rJ6T%l7?|prS?kzZ>g(wk*cck=I5_E>Svwk8J38ptSR3is8rlEr zp}(I-=gdN9Y-Vjp=V;{M=s;)hWbJ5XWkhGCXRT*qWKVDIU}OEC7US`x#_aiP{579@ zEnAZgCO*9LiseB-gyF5rrySN+q?bt5g-O7^Ep!Xq!F{J7VXn2W2$bRImj_Xb$Bsp&kk5FUa3L{pdv-~h-*zO) z&pJB$k*SzHomo5~zlIx&bClpWi@<{q3!u{Lw zCA=YP?Cdh7`^lQ3u-t{LaeHZmC0-%+MPIGAz)o=;M@T{yG9iqs#elm%6&goq5MW3$ z3NzYSXR5X%7AK9_2g9eU<$}^IO^VmwPkAN}6MD9uD4tl%4Pw{0w1o=~1_2v&kA`%vJ4cvj% zvCi%raJVg9W{Wv8x*5+geP-WoX8z*)Tzw`q$9)p34%AVbIYk)Zydgx?u6ptfq|kh_A>c*f{)(ftpg-zsArTt;Re3TRsp)-#^}>Z#y$SPoIBf ze0qOmmfgxc?LHFqL{p!>@mPFx#+*XBp1N>9F0Q^nlfFZZC@T34{Q@rSNdJ_p$Lsqn z_rAr|K2ihdiYd055n`#Byc>KZkjN2CADgjm_r^-|@ygTf_G9~#+jArF3FW?1D^dvQ zR~JQjXLKwTGjx&OG+*W&P5gjGod_)G{r(s?=$UoKw(ovL^@%TxLl zrd~<#dr8eujVDwk3)Cz-sPVLryfq(hwzeSZ%Y3)3r}%68<_SR)0Gg(2aE?U5v6q}{ zbq@OG848X|Za7OM45z%AWNX-RDqUlK&`C9;)-dxh)brYs6JweRN~6>)6Xfn_WMiT@ zgqWkZlHY9^NUQasAckT~(TQ%Q?S;|$hPw#Vn;S2A^jGSuw%L9E5LObwFu0g7wfdDT zMREYO5lfcle!A~uRME|IU7XQCTp7d`>}Y6y9B}buvE%QRptW=RI6TVNKE3Vda;0X* zfSs%uP`dPX+ye*98+OY5?8|o;*~e{)NOP&d{!>-Sc>W>slOYrDddAvLn)VFP+F{8X zlBtkw?3lDLcpAaqjauj8B!QakVaLht-G*{VHPefvsl~mDcVPCFtNnpJ$*$!}*B@eG z46m(0HL=>8#9ZgTG^scY8GjT+3|Mg3!bve}hgB%`a8%uu;f^LAMA4~Da^TIM48K5MeI{moJ-5**@RKLSzn#6Y zjRPHd0f*3_)Vu=A-B1@79!QKDMcMth z`r%-{v!TC|J>*BST|rtEnRO3@WHL*cNH(4g^XkGC>tI@31`uV#)Gk4C2hl6edmK;% z10fb-S_!49chRChMo1Ly`J{|*P>8v_L3!*%lF%8SN^k2&*;tzz95foWA?l#fQDB7{ z&}A~n;vkjQ+FBl(SS$@on_8R0%n8$npEIQGHcBbf3I+rpA~1;u888(9Q?*v zc5yQ&G~|xO*7!3lb(=BmN&Nx`kmZltE#{*?HQjC5)?lNJND}qKKfg{3Pz4k6>Tl}} z>MbR~%Fp9Co%0r_@gYtSl*ngA=iOA_Fqajv+s7i;6a@Q zwK(`mS2odTY*svbEa|m^54R`&N3e%{dEDfHZBy5g#DUdFFZQLET_6)a3oWu}>y6Dp z2jAY*C9kG}nR9-=-Ru`Sd3kOYx2{~I%*Tr<;B9rK(cWrv9wOBy|iA*G)zY!=wcrir{K>as)2^c>V&ack>FS55YB=ue6TFrc1}V5o?Kkm&7y?X z+;B@nkLpoL^?}t*xT9s9O4;T)Sqt>Bi%d8msR6cqEr5T^>7aRqNXIoBfu86ysw)r9 zN%S0x0kAGz>xhOkiv<E7H0{TiB@F!yN1C(Au2G>N`dvoFR z89j!rFwb-Vm^T6F4jqwKx#vb4HVoreic#7!N86koyRM{HW=JTs(9nhvyveqtLd6kK zi$=MIIZl3B*zo}UE`%MD!3XW5Yz)2)PWRuF$_#$rs5!NLzl}~2TZ#tzXn_%c94qYv z40RJf3a{!#yaEzV0|hDdFQj)M{I+6deENwUu#MxG#zdmGIIrl(>7}b%kgKo>DpOck zg~t1r{YCi=fSqFu=}CGp*%?6zA-%f{umJ=BSzudj`WQ#8V~;)r{lR-rLeSDHnitE# zPh9LznV!khZ-{B#<}6x-h;QP&R}2u42{H)2V0yV%&EZyiV3iU8Su#xB4thIFKh6hy z0a5zvrriKiTYXs&QE<0+OFgH-Zebek_rCxy{0^--%S8zU~77?;y`d{VT>ux5HdYZ zpDygB-%uc{b|N?sx{G+oC(BVbgFla&D-nTN+iuuJ(XlN}N86q}1LVjakZQmoeqZrL zcoIINypAE3h7_K=jt$c1S5n}SA|cq0F@}Yni*QP4ieDcP8|+FQr^At!*tw%>n|jBS zFm%NQQ96P(asiCHeM~s%jb$Zm6Nnk()Fml$dg{C946p~;Lq&WoC5Z0W1*NS0@`ior zc@1*OJwh(Q{f3uBBA}vS)r1vnF~QjZ{5^a@0h2(3My8O&MLw6Dwp=bDq;}y9Hh4Ph zF9A;R)q$)+qk#wPp0c5suDno`=)`u&4d5`TxCZ9Icu(w3c6eZ2S_Lv9C){0K?}9)C z;OtdbVUrz^LrR(8Oq*1wv(21Vp?twiB=~-7jLsm#RQWy7*yQXG(v*Ayz5>Ds#*j>y zFn;=lPbu6zk0Gl)BawlL^S2~UG}uZ0GUK=s{%OI9LQ0H_>xt-?TLWf(xQ8UR{)$As zOU~N9O_839Ms{7oq+e2Uovf@YWBkx4w&FeRl|`NgeuaJ|~{yaL?UN z0MzoP1sjf!(6!5%vyQYB7A<^FMT-Hvv(!BkKW3!oLmFwYm0pIL14-NzM-Pp^*9hep z300?W^|W6q7ddatUSBL;yV8Ix_cEGe_5)i2)Z*~asj5Dmel3;NBvm#zpR8#PPhZbQ z&M0LGyU}P%2tl;eUw4k^3|dXM2f0j^ z=qPVC(N~7m?0AF5M_3}D0blxfWv1Kt%$-0Oc!~iTF!;y^#Ry{iK}hju$b7#{-6!$)u*{>){P{eyoN8D{Q6)ZN@a*Y1W37(x zBH(9C`7Fm#Z_(QEl_o>$MTqdgu5qjoRlSlziujdm4HyDhr@w8V6`YNMcMqN)WpGVS zH#I*uULH>$FAdyg(o6E!;(lYkGUHfY?2(CAJMtboY=bd!6OG&=2iWpcz;$(-T%|x^ zKM{*aBDvzB;J7MR96Fw1b>hosEdymI5D`KTiy$i@&FA{TnmHH;BLPF^p39_jqY!Wl z1C<0R5t*YJqcSW_4KvgS!MeSaUmP?}&8l(lA2h$pq??^yXu52+ye=}a{9#YhF*V88^7a#{s{FOSi2r^os6st$DNxi*J9c^;S4u>vUZa-g!*# zed_?v?tBja2RB(;dTy{Lb8O&6ux|xVIb>*$nS-0H)v?&FGr#d7XfQ*jcu9{~Op>`9 z3E?c}nH{o0fjI0II>KYM-#NrURE##@3goP%vagasm^4PmPBq!?m>o3=1{>Lau8mQ6 z&JNiQZwCT6Y8^@MOo?E%gQ(-&jmeHTl#c{zcdf9YajuZVaZ%dl0^Dva0M?f_RP4;v zxr+(b>x>)9Arv_bUvF1^oBqB_QCj|t2!NUk>>zcYkeb1<*#$H~ zLFW%@IX3LBjnRd@gw{gvKYlVJn)|)0@lvvd95cZTJfm$Fd%kJCq_^^|m;D{@39a}wo{EjT6~jtGu__~K^I?}oK|-=ZNR`}Yv*WW!&fvMRI%nGqFH3Y)Z# zOp(OuHls-_Ho3t*fCMBmYo;VJ&y|!k+{khPFC_Ki)`_ldmVUXR5jjo*I7hc^z(awa z2%!(o+UC-fSwaolwKqPjn$~j%xK3J*`eetz;4N&Jo94Sj!iOuMWR#MD=T zuyz>tpdom?!LwaXpj}r}P9b1dWMhbY$c!8Mqqu`fGWd#B8>1eCplcD?GatRgNOj$D z_`WX@bxId}EN`4}SHoHJmvTkHf@#NhSP(pvH4H7n1C9&X;v>vKyO^)klSytgCy3AS ze5d?xolLFLYf40UKYc`DiAs24-(6+ENwN`GkmsUXs{55fTZ@jw!d|AKHI(Y>;e$LL zEjh8|gZ&9EtBIi6Z8hCby1#uFy)(DIXGxk}cGcx0m^767 z?nNb`?Xf7X86H6T2npkOGlEhhP#7DJGCLxV{{O zLjiZeFNEKAoCLi5Ds~$p?{($o?1{$rR*A5ZYsd*P7Q5Z1cfM{L6>TvQ)9o;PjUQr- zz|u;e1%hQ1YxNqeqGa4=v;{xVhiS}jo1U#=h1Rn>bSx+7A^BtreaDZKXZS_y4Y+)P zfyZh9h7X*J%4K*)LjA^ef|zA1Wfm*8b4RTfqkeBcxGtjxdSmevbZBKI@0atses)ij z(H8=8Ms(22*Dl0D^9GB9S4e|pwI#D%Ot-AVaW3UX0HW#g1 zG_gcA+3?laef`|X{n>Zkv-qt9H|g>S{pw4L__2YY2%YN0KaZ#V6$r@-wbWCegdw~2 z;`k^T2E{uMz$8*EGzvbmytHYWw5%dEU#@7D2_4{zA?O&d*JM(?CzAR0Yd9IvmSsli zB+TjJ6jarFHx+7(Ay(&IHSg>@&`X316QsjECcG?6c_&VD+(GV_;TSE98whPvv%RDV z3f#ST6>@g1qGDa6&hyNl+^h#$X^kja9rC?Lm-)-j)zUOD`lQn*w5TwXPBxSik8vl$ zWhYojaue=EwVj~wXqq;Y0zm*L^%IQ~_HB5=%{W5IW>Ng~bcPA;AmzUyZGiUg>e-Eh zGIl^-Vj76D`9_P6{W3OyRCdJ}gT=f`iLevnL%%|~CoVypC=j;?XM$3Lh0tVyZd*@sJ`L&V*VG=s`JrR|#%x71tZg|>bR{14u5-`( z@@13w``=yofkoA3V@E^;L#ED?!~nN4;vICS__|0wONknFo02r;C2G}W`4jjCeDGy* z!;dH!zrDo=ikQI@Xls5~Wt97>buCj~#3#gtB)ZqrS^N^PvkZE7ZK&-)lpmqxZd|)m zNta281I+WlRyL}PaQZ!Y7)=C{$eA}Hc_zp?B__dEOJks6X0cK%11NXGf5tr@G6jAax;E=o_BQboK`hUg5s18Q!)^jujuXF zSb*^b%&75N^cf~!#oq}ajV*)7O}X5t@XJF3-|P=7D|HWJE4z+RUI_fs?QG`g2B->! zPo)g0W=Wzu&f~HKjUs0}5q>x$C@1av(T0^J3yJZTQO57@lklWCiS0I1x?!u`;WY2G zP<-nku7rZdJPZwy$qDuyMI!EV5#GGUieehf7?kY#71G*K+~}@L93o>G#0$Ai1gD*y zGqR6Kr_iRzTYb?mT3@RFaPxD#?*gV${dVAfOupO&*k(>(pS0avf0Ow(uD>ABVa5DB zkR&Dgu5;gPUrDbe)+5R6?52&oZKHN0AGJATnIpB1Ao4*ePNO)%vT_nCQNHW==2#F7 z#RZt$wDVEfxzSv&LG?kpb!?4*x1;=*V(skfRrc}xyBI}k$GVQ=cmsK#*R%42uPMbv ztDww{HZXch$59##&2k*XCB^y_8wcv;;mA_MT%1CQ4DoCf^L1w5Mj{7_GKkf>+NK5W zhz?SxEPhAd{;k68O+cKL4$7B(*S+!^;`q}h)N)0hI% zn1`!Hy#;C3x#yh(4-l)Wvz9+gi_;{ehKD%b&ZSSe3)?VgHL9sE2-5O+SQp2 z+S0R$S!tM+`^B8n4wCvNam;inAPw1=1g$g$+~1y9Xx?|?OQ?&8{HlsXXhP{4Xxl&N z)l}F>f0X)VUvgB?{(wr(_OnKk4`;A`eDNBC*~X=7kIug!P8Z&7}C69uuAEJU$$0 zbWQU}^2giGW*;0F{o&`WII4$@@xk%Nkm0_*T}4#y^~1?@kT z?Ak#oZ`y)Gy!rBIjcO|{^FA4{hly-9T-FOYd-|xR9HpM+r0e!ku4K#whoVUsCh`!D zU|M$g`?Q*!dgQ9}yZ{)N+UgE^;>?nYs=|@Qk3G42JH}`Cl3xn25qI(H#dQMl`wS%# z&>ts%B1fK-_$UUABX!Qmu^Y<5fg_p~Zk!4yomtM6H$B+#1g7yEt~G8|Flqh zIdW7iGnA2)(GCLyG;(N*kr|%L;~Y3gjPRmxZcEK;GKRm-HV5P1Nn^(8d=R69CO7wF zKVVa6Png3>!{O}x>!H!5>!Sj#sC@J~~dqZUj)?Zttq2l)mJ zyPrJ1>Nd9uX1kN!9xmURKk1E-riFuhUAgeX3JDQ8map?vP4JuuN*61ROUDk%zI!U^ zpkl*SI#zrdF1E#bt^6QcjFXD0yVx$NKB+#F32ZrOLanbMtMG=t*b?9B#x&qDrMjuJ zEbb?`b(rNS?JSn9u0w$AI{sy>?dJWokwPEpC&lNu+8$cR8AW| z+j^=%(y?}R0p;-faJ5X{S@RXc$~J# zF$9{lsj<2t@Q<{Tx_EqAenkdWwlbTX&XgeDCImO3GT1AB6O>wQts!~-e@mr6@@et$ ziwx*B{Ikd7z!*5Ij^FA}ldpK-Yk$4x=L7d@5?CGS)t%3(Qv8KJpywTr5rCI-GUUB>ddDF1-fdYPe)k6Ykp(bV{S;Tbd`t^nY)P(U!fV zp_QJ)-XvK+@Z!qp%(>;uXJ{>~g@0<^<4%8moJ$w4Su0NsA7Oq`Add}DzXA~$W?x-7-n3hmU4qT#&@^a&b z2;ji^>fp#9141XDNKlWw*zv{^RKsO9*|LBEvmFQz95 zqL6J-GIY@Tu)a_TF_`vY)m8?yWVdHi+x$phFup4aRH4cIWlVz8(O`Qu!Jfl0Hqw&8 z8M_qF6;xH70e_`#i18h|-<<*!hPssM&~G81PJ@sk#l{ofAGaIIzj6LSy;hMO8|*;( z$r336RwvtDB!;+2f)hcP5mvT-hbFZLHAD`II8ssSx$WURO=JInz|4kXwC_xZ^Ouxyw=rxwylTQ^FZZ`uH1^ z3!fni-Uv~UB6V{`Llx|aaMnr2oRw(nnjMgo_PA-I{$uCvQ`By3SFw;}6)9;9(~VY7 zELbKpiB@u;QYMdF42=PbG#o%eYj3Fo_I=iGz20|SJpLsy#+>V{ot+UDx0{y81~?5| zse%JB)?efzu%Q?0F?YWb6GS__nI;q$%1@-snKf|CC`D?35s}Ytx2u)a<$F;TaGEyL zHw)o`aEDrF?m1<5k!|V0+(;8nYx!~3!o{T9psi7x0EW*BL52~s;F7p1z|&ekyFJL_ zH_D)I6(EQJbPi6H_EtzmuV z*+cSF#2gd?Y6G;e7F2?6rw~FFsLqN=s_Kb0B15gNrl2@jDBAjSwXeKNn-i$Yw&-fL zve{^%V5udk3rZA2<7XNj9jzfa_EE;@S+-URu8DV?)^O?)$7P+ru#z(e08(@f9i9XN zea8Pusb{ZiQpqb%{3D5OP9jg-uWH)8iV_~!fevu$uH7e-tbj&U!kLo0jmXzGX5Mv9 z`&SDc4rByRe&WV(k8_@A0Y^1JPB;FYKe6q6As-Y~ufHSbWDDu8m!4!-(Dk%^4Uw`M5dwI3?S<`+dE`C); z-W;K}(>J2P@#&M!ko0^X=pTt(UL6J2xR|z&)*RqVLtNjDbMNNvuPb5Hp`o@!_dgj(*QLuQ-4ZD_WTeXt|NJY)r+ujRK>=n)HfC4G3NI-~a-dA#fwMbRYu2lVBO zXBBZ=3;MmlCKu?5QX8p4mDbK(Swl!xE+t~?ZSd22x1za?a-+Fd3k&LQq=j?u#LOet zsIQwsW$E~?cny@;+UtXzW7;imibA<_3$vrcaD9F*8V{4`wPLyK6xVj6UhxR?Gswgj z7QG!}8{+cQ>;^Bhl{_F$ba{}uD z3%qelKVC|=&u!JD(0UUBe>-cO|Bwo=bPHcopOqNrZT)#ZSoT)`1)$2G2})+S!LA5{ zW*Q1zU6+~elGec!_dqrQ*AT;Aax5j#PHMgyfqDd zK2#cw_E&31g%H1+A@Or30@)N#tIKyW`o>^{jS(ECNhc~Wlq}IQ91E*xI?3Ti;h2eA z{fH5uIb5H1<&4`s4iAJb<<~@8qIufudqsy)elFKfTy3XRynDI>r0>PNz0kL~U`Fl1T z5L`63M*ioQ5>t#AuSEZQ%#(N>EZ{)~Cu#TER%^l9bI#4o+|>w}D3o6pWKLP}Pe&p` z7)S(${bv1o#`x`?G$UKzPmF#ZW=y8?w6L(n=*IHY;QW@hUPZZuI-^9tZ8!SY^0FKv z6Y|@O(17kzoegSJfl*JZFvuMN+)`jlF=I|MlivV0eJ|Jqf&9rZ8AUfY_s7`Na&QV&u!=Il2F<3+gh0qOUH9!b&&rS-gwi)US%V4k(IVlRx z%h({~w=0$;T&fisq@AQ7rq$G)u^+kQ5~Z#N7-};XRqml!T(zVEH_p^E`fG|5x&Omp_qG_bjvkLV@vc7pJc#_rOjCrt5c_+P}5=Rm(zwY@LDl8 z%_}z<6TE)-BMP)VBDtQsPT^)a)=nmwDN3oFEL_OK3Z#=NU3^;Rjc`mhhUYD=n)MWg zOU_wQ=it0Xi9eU##%aiwXq4L?g|+i4;NN@TrLTKa{LDfRsA=FQuzx)*?d8$ zNlOsCkpD!XO#dr|D*3=^uDH(esOPuGuD{1AJ)ep9)--P=t`7_dpVjCit6J_d3PIZ8 z$-Q)i8%!~nFd*F$=+oYu)$FQ5>LX(p$?~^F3aV59?32_aEp!lQq)!x7>Nl{Vo-eXI z{@DO`RQ^nezjM#>8XbGVh*$My0+joq;d>W+(kZMY!^}pm)yf(qAI`^PdMtQ2l3=os zq}Y#@{b{e-)`c zVrCk?IRBbvTTSbD-2c8DTt!5T3yzX_2~*N_C$^}pKAgnrDsUV`PYJKJ=Uo|LB}0cB z)Pg2_M(MC2WvTfrFGLn|=5@c_k$bkcE8Yu<#0OgvBr70&gaf8?gk^{htz}y65GKQ(Z`R%)^R(lN=$P|nX__bk76rbUcro*$wDnf+N7uWP zzwbOW^2$>DpnB2}Do9aQYVJm+v{dGS%nM<>J2vb3Oo_F;{W^s>>1HeoyyB`7)J_se zigp0wNoa0?iK^m%lIycj(v&-c3X}@M2g7>vTUFj60C(=gE>{I?&3t;%_hIA9=qN3JcBR?;hVG^}}36G($87U1E5%T4>t` z=zyMuXRfRl+*HIlj+&h(4#g0hYHFzSVoxDYtvV&tS_(y{HmjmqQQduYVGnW~$=igl zs7D3jIOZ33_8e+H_~;mC6r8`Be6mRbrG#YaB?1C8yE69~8MvI@)#-*yWt9j_2mHf} ziTtbMb>F=%mu=rfXLtH7hVzYV3U%Ny7*Z+1T}A>^@1PxVMOy+d&&c;}uaBC_Fi|h| zPif9xXK!;f`^gy5tuq@pBZH^(rL^6!f105OnT>lZ(kU86M!igf7;#0q4(lXl^eWQt z+RmjYsKoEfepD=Eu^7~^@vL&Osq^#4PihX^`x_=^E6Qp!#^e5$D*=>w(I)c5o6V($ zDMrnY*i&M7^Cj4ByFI9`GdDb}gcagWYH~O6<6GMNrY&lRR|Z&NX{SRPV`Xjy1Ml*U z{tkE=qWxf%a$mdnaS*9AVmlX;1E^1MzbN{ne8J;OY&;aDf22{|pzjK88PdK#| zu%rZ&-sdaB2MIEn0>B+abL+sARiyRo&IbbZMXLK z*xh&tvN~6*D)tg%IM2nm!Ior?tHU7SSl-^)h+YNRJGi4=Cvd&mSZD3=NM^=DpMuuy zEf%T1`}Rcsx-*wnl0Wh7zJ-l1ahW3-O=4cn4gw4s)9nM{1=_2{k=HwT1fm;#a5gt6`(<@CQ$m;!7JFmtvI5bgOiE?L8&&3 z`aQyW-Gh4mr4;N(TxWVGKP^TpMQ0*Q0aAT7M)Soqao~-wr+oQqK|IPmL5p>Z$;4{= zSy3t5WD4c6Gc-a=}ymPM*56h_PBqOT_}I^`d+6iykKmOL5= z?C(lFuW>i8&t^mi+cczhsKk^D@Cp+QT-P@qcDN#q3isp(Sf;#7u& zsu|esND2EVxv-y1E`|TL;mWRCH8mD%IReg zsHC1Q7$nmGAMSv(v7M$t4+t9Ayy@<})DxgCNH$T(-fL{_0NLf#_E@u@#r9yf#ac6_ zOPAM}$e%1We}(OF}W<8}AEy0R-?u$0)%_Vo z16sy-oqO1Ya#kd(!k-4jlB1qe7UFsoN}~ z>h6*$CV3SD;(iWii{mb}Pjj$TprhhzfTNI~03RV__$&+h^qKK_@pk&WIq?aA-PJ)G zed|g4Wc-|c?wtH`_@Cb_hMvgwQhym_ey+YL+;&cM1~YdIjr-GDgFWl3$!+}~cMDhy zXTV4rjXW7tHd$GG;LqLvB070I{3^NsrZf4u`}TNyshp|PL)Zz4?5+IcaP!CQXP}lq zmuBZ|bLYl_0@1MqASw<;^aED%e*Mj+Y@g^u=RSS&NVwAvgeGi-?r|aHVF0-pbQ*O) z8VzHP+3t#rO`IhU6;y41IRrt@|2^slsYYcpf+hwDTM(R`O$>71g8t9oer3=cIFlr| zFoc8|+zi=~YYpLva27LI>yoTPhTn=Tf#{T@oy(Wmr4$`HuB8Y-idI0yriZRiw3ACe zF=89y1-P@|gTLRS|8^{r(`&#{W};IZ&lkG3sn7m>1#Fm6p}cP891uRdX;iJ-J1zts zt&uWKM?pH<{2UhU(Cl3O3&+?#d2F{brJrtM`yhO5e9K!}V4RFqcGDT=v3U!~jkp+V zm3=^oc@hEt;ydw9jJq?EYmZ8D&NEc7HLYj5(nSz`P3(C;{kQ(zT^@LsOEea~V>2V1 zd`h|UM|p^?{XsS(ts&mJ=99peXK^+1770P-Z8?VJtfS-zHxZP=Oxi#zE0!ibbM`%EOd+JuQSQtoBODGP z2vd3W8C(#jZv!Bh;5dh^?uRA56ySu5{T3BK;;U)W+$@+1y1d2`$nk$insom_npS?K zLy1h#WDpr7^!ApUfdpo;CvlSXA6Aj`g+QZBr))%uOFp8&&0YXB$z&9YFY;>7P=`Oz zgb44{jufIarY*H5h=iwvQ^jdW-z&=;Q>nHEkux=jker!zDH@3#Ne`MzW5IEcI%G`nne)duz*NY_8W`s0dbQtZ3s7S;D8V`7dy)Pxu@{Wk z5BQh8)>ul6Af&LaMsT{n%*CtUdKY3DoxtfFzg~S z3A6VEyNJ2oCAy688z!=!Th~N6$^m_1OBj@f))A%n_940@;k!gY;^f*mN{hZJ1BhTs z6iI?w-)tDdtn3BHRvgcy5rfT$&rXOe*WG@v_``qk&9Qo2-qz7cuNAa;)dW=^_F{sS z3}aIV@4Ts?|AU5$O!^NES222gy{kBcvB)^y2vtba&2X{h$$4JY0bkdpxw)E#&mvc> zby0H3oR+ROFyD72Ml<~zpXMK~aPGMrg5xBcrXN90sfHdfs5@UfEm)5kdb^4k(LKf~ zkA8x}aLW-LX+eM$`b=95gkEV4#-_MBkG-W34c_AsS1V|3#}f^#`G*WA`9g9b6(aa; zhgDH%`9e#Su)gNQ%3}s_l&#Ddt99i>L0R!6%+we9pD*3>27u@$kmN*NdLUJRcUcPq z8RujpE!!ancfiAi=+}GF=FIOTciVxQhe{!1^T@igC-U3#cHszfRWSvAwI>=Kmz7F4FV3XyZri$N zW*R2Vo!*S5yZnZCub{FCV?8xoD4R6mu|`2dQ~Y+Cc+%ejQmeUDo~o;0)xVlD`k#|*aV+ZDUS z|6rho1X;oX<9V^nzRl^3mun3!&I;$nVQV!Yf~d~DpTX0Zj?;(m4M4wkNA*81; zvWg6bt5h@ZDxLynUsKVVR#Q;uXN_hT2I>E@YiWsL?vVphzU*4S(7)TYbdJtvSew=j zU6x%Y(lOBid$~|lA;*C3z&fs4k&rR}sfR*2d}u^`VxW2vDx`Yo+E7f(K8z$dKUhFe z`T0^~2(xm__Q6$Moeeh^*{~im694DFZRaa>AmOlEDHw!F-bhl45YkH5D}|n13iZ=4m+raj5FvbX)|y?0xXqq z9CVPaZtz$mS04pho@_Qy*Ajh$2;Mhpec}L2-9;xdXD?(D-?y!@Cf}BR$-r7DF7q2) z;*+KjP6RuDph4>pMrW#MD;=cGhqe^XtUdzd0J{sNR!<(?EL_%<9vF?Szx7&R_Wz{U zc5~l%UH+}tI&^;Nwa<5Dcy#KkM+|~6l?@!_1zYAGW?WS2#j9n@FqE|X@$4GD6IwY5XAQi*10n@ zkc|q-x~_p!bm`;tMa(h=`3zvvg9XeX5*=OR$%8J!cS!_Pija2k=y@N7`dnj-Z=AUi zy;KcEZ(m-2Ut!o-g~~4wSgw81Ee;lR{PJLdz;I?TwTTV5PZhq+(q0(l~&46 zTv8V~bBnxZKlq$J4eisvEwz{zC;7n#ziVlO3<(iBf?AEJ=)Q}*n9FZ`C(;a*{Y+`s zM)7u=ol{_F=;Ch)SGE2ju&E&W=Rj59fcDqvwJW(y+KCL;$x18x$hu|f-iILkbz4oq znZmK*GzHf;^;V0x8br(JpL>5xy0F^m-tbT(F!VUPXK}QvNXBEA6|*4 z{-}qLWP2;Fj5uDpS!$QK)@|GyFPQ5Plv3~UJrC$>0y-sX`1rbiwHP*3To?}j*jR{qw(?c&5?5%c0vG#S`}tL5SKGIi!Z0WLhWl49tLWt7nG4QAKh8p&n;lnYB8Bzb9Kne%iGb z>e2pg;zGl6>m>)%5-3!sGHYjqN||E9Z2E2E@_3d!sFo@Dg;+h^{3IUOXH!wa;x3zj z@99oYX(TW)m7yTrXUbcu*PfRkYIG$snwvom{tqn>=`^IQPa5^fyi10NVr)yJ#wKuj)$SqcCq`R+pliyWT05L4_ZjYipTXPIH=ylmf z9qj#}F4>WDKnWx)8FehGCA`%g;3L`7hwI$4>kUYNJ-T_K+o-%ehFa_8iG+`lxUSTS z7G{ij`9TJ0b4GZjB@KZ!CAx!Pb;T#G>l?1*d@Ps$P%A~#}?40-H; zq{<)ye^XqYoB1v^l9+QxkBG^zK@qQy7#P0JZqjLhFQ!UptTqJFUQfQKDx8-uI0^b0 ztV-qaIMVm)tjzt*fQT5~SOL1Pd8b2o?3q1{xmDYDeeK-Ow~&~Viv9KnphWOdZdtE^G6xwS zYBXvGEdb9DEyOr4n;D@#Q4zf;aTrur@HhY7(HY=co*i3VDho^&PD?|3xW0vcWfNvi zW<;uA809#+vZ>%%O01Q2{`>MFo;m!3_0ePg0Hu)h>}kU9r*$H887!^ZffnUVfivv2 z{Iar|Su+xWk)7+dnSXbMaV=Zz@FSt;({_8XpxmJU##TYP*QZSQh_&)&Ei>JlWt?R5 zXKg6;ChsPF*iV~cXkvO2#l}(}^CxbceTpg>bEawIik@7WhZ|*wxl22uU1L+fr1<2S z>NNEs2A7Ky7-xcGm&eB|wL`h<{DSKvGl`UJ7s`2`D2 zikC-a=CLOa4;oF|-#krs7CV6KPjej;bl2C>E+;En08eX2B`%la@`ClDDQrG8fmn`O1xL?s{Zq%JM;Q-zxfFzlbV)CJo5t)ND9glYzw($i!q+YST|XS z2dm(}rO)G}H0?#c%16ta+#ar>np6ykqM*lKRkKo`67n zD~=GIHq*766EeVA1%(BoW=jQBa)(`2+dP@Z6Etr&-)T!V_y17Sm(R1dkoqo3fbwt= zRzP!GuD{Oi59ey0s8@-oGJzupvEge;GB%i;s3x?Pmov>sp}%_rEUKo2THjf{0`0X5 zS0&y^4XA1ssKEIK^E0X@Z(yWTqI4Oo_{dnxd=n*#B-9PiL&e=HxKZ`KZNa)TLkAnq zPq>$A3t+Zhigt&|i+BJiP9rj6^ZL#@ahcbi1w#0ZQf1rB)Y6(`rJ{F_X3P;1)**4K zJUxLo!wCryIqRo|1fc?lk0?I*8tH)r5JC6_$;m8W@EjPG{2IMGx-^+%5}p*gDNf7h z`XRy5MNXp-xm~=l@ORh20NUc@xzahgBMpF;0lEP*u(qJpRPGu07R#5 z>qMo;_-s2wCgz)0hvcC)*+~k^JWV_i-)3Xuh%0j*iGJxBrP=Bj7K>kHafgz5dh~a! z`NZ2fxIlGDk<_kyx_Z=2^TSI^zcBZlzvv^K)-RJ^s#eZ#Sam4%l#8pt=G~BEv{v<( zslkL#LJf^ibEZYf>sG_=bGT`9#HD|^LfyA3SWA4b!q6UU zB1QMi`gd2b(emKaw%`i<4_By*{NKC6J=Z!E>p!j#D>K^iX55zb?FzgJ|8j-91dE-t z2t|aJZ&x7pd8oAAb$U$EQ*S&X4kpvi(iU6RReZvz<7x_bkfl!TwFUu(kbk0WDBK}w zK$;^x0dD=Tl5C1Oc%(Q`DfW{4N=lbp*xled_YwEfndy&4X+108VV3Z47czSFMr3MaqDdS(Py^|Sv` zg}`fao~8wq+<&RUQz#nDBBmk4QP!nm`ah~L?edQ*1SkDV6@YZ{PYP1Rix%~GO0=7t z@i~6tcSlDd(Dk;b%$j81vH#gb$HTeFVb1=(gu9!IO#aEcuc-Ye@H*~~VlVM&n-i`_ z3y|}rF_Ta<6`*t6Bq4)21O?Ah8UhJAct914@{b!uZ#Ng=BcOl%XWJ9~IbR3P_xMcD0bVHQ|rG z4qZ}~7qXIggT+hH)*jFUqSD{+WLenCT1JW+9jfpS(KAkVZqJ40- zvWjf(7>0f{B_}%l$9$`~$VXXv(R=n-Z`R@Ys9KB!sQV`N5~b&Th5VM6y+FIy_4Cd* z-P4#UGVrx68B=+U>fAb1af`<0z=becyBBdBIE|Xwsq9^7?aw^o)L|-0A?Q}4z`h=p zsd(WmA=h#_X)cIP=?tlZ=P!o#Qs9o^RFf3~w788q#?YT$f#eh6$!JXL=A2|-6go!x z_l0gNnlc>Ph%0QiDmzU-NJGI?9++9CYEXPka;nd@$3+>=IaPhpp>gl8R;^AJNGcwJ z9CUl4841j7NEf%52s3BHZ=0J|a<7A$egm|O6Zg;IPiF)M4IAQo&@pO`#bq_g5Olb! zxY65sOUy3~OPz%g;tbvmS-~vo@mxo>UWX)0Mtv0}1{*32lb{M+%_9r))L)y6nHts* zmlK4u|EQr(=VjhG*N()JF=7H|yF;)p+V@RKx!4)EetfPb&!DLytdv~Y^(n9yH@#LR zbw=f1+@^avdR2$>6G5D)4pn5__yS1xWXU9eh_P zN9p^(xBASLHK7ad5u{cgB5)eC(Z0LNtNsF21PFXT_h&f%{(gdEK(1fO={w5jGhf(s z!5H_~RK^#>!7K3AYxdN~L$fc4q(FdUQWD{<-p}%@BR^$2$eXY7?RPQES9CND#RXf? zE^S1mIp6O}n0L_uLf&If40A@jT;RE7m#Vl<4kk!;GFu~qokUH%r`ENPc5Hlg?cy4| z%nFkfGuU#?JjHhv%P-BL2ILE>c7x@ZY%O>Bq|6X1u@V!LYLHlX9+fBy-srX6r=gHs z=ESghe+6YE<{L`&y>Ofo>Vyp3cV%KF)Gtsez7a7`E2f%$!}6KZFIDfu#qF-wuYa1p zf|zq*Sfqh~GJk>mZ<@ZG|9el_|7a=u?k)SjQu_6OqXA9me>9+({U2>Wb9OW^GNCiI zwsZSe1Dcbwfur;Pvj6P;yZ7wl`}NQJdDmG2UWW_$>$ZISEP}Yo_@*onG${)HEP^6h zQ_DGB0(o1%QY|)_&M0$5g_P=IW?>69(dvG>gSpr%lYr^o`%Pz$h&icMV=Qlip1*hS z9jO@+gQ`cBv>V&1HTe^H1-1WxiNUV+cApS2;4_hMW!};B4Ya`x?_4%S>W44-kEs%+ zbzu%X0B=@K>`@?#7iZ@9iT72{HY0AXeA7io@62natq)hj{3;z+V~wrPvhQN9%&?!; zgZI)`#7073j|`;Vsv;ppB9KyJ_N47gkeMqhfUTwB<$TGQv97;& zV>2Tg@u)dgLSWi{JR338=R*fU%x8O{`v-38nGU>|6Q%7EfiMv&&o5nWPrB(4i;8>_ z5}pTmxzkHCeChA&5n*m)<#!Y$(TT_B0(I+id|jaX<6~W~>qEc}0KN73_Wk({(vQgf z?aWQ!NnrbPeO;jQgYNy~Xp@2HV^iLzd0X()&+jSr$```zlifW{?HQCS077Q|wkRie zoJi%G?LA=IqQWQG?b7eb_N&H@VzqN(TGcQ8`FZz($L($VZSQmY;AFbk@s<~N@O!l+ zp!*{okU(*E^OpvTl#3ur{G+oW_Q$sGGv_o@^7PNFW62kyX?lcEGas&uE}6r}N4<>p zhkZwYuMWy+hhF#FV27Xk6AKcI@fSzj44^L>;Qlmi2k_V4{xG9F;jja6@#AO5Tq|Bb z`jLXX$HqO=jJ!wJjDFn`fAFC_hq`?M(|<&-oz3cVE6Kz}zIRTtCR=-~iF@BS{_$EbCvNwJsRIH1uKs*&^4YmEp!XsMaovx3Qgj3m z@>5#Pa$*u|lO!HKFZoTy7iZhs`&VX_h};+g+|d#~C01nBzz1X1>Z zogvNbY3WR|GZBa(ukrInG6sDbE_{!B_Y?TAOS@Jv{;IbwE^U2l4Ur8w+2~^8$sula9Mj@eq)vqcMaSNY3j3DKrXASfb999p2b75Y*s?oBh{p ztnYR9o8JA^hOhTqZYH7ul4K0E0(}SHqdXIw3aizA^kyv zJvV0^Ef2DRg==|w9)Uc2g~gQ~vVRqYuLi4%Pby~mV<2a3^~JusbR`y)^+M*6ZvpyFDv2x2HBYUH0pk`Hg*s+2F6T^{2MKu#e}T94%J zBPqJd2d|_p{y-xa^!WYDRBzDZ@#A7=%At;lYV_|GRa6Re+36Yz5ex}AX9d}MlA2t& zaN;NIi00`+Z%A+pcKENPO-oZ(#b+2{RjMBakx6>ZF1YBMoTvKu zM`g40OU=h!rJu&Ucz*|;H$Qf>8M?s+sg~v^eqh+(^YMgIY0Q%NEuXzO)tUxJ%42TB zc0q3DjLk-70BbWr>SIjyj8F7bGNMC}@bN;{d_Ux_v_$Pw2H5#jcu1|N)7Z-3%eFQx z+}Qch-28mo23gaPeo@;lc}X&@%+Z1*=`5{EOF=s&t0U$T*2cobnrkQHPOKTTms3zg zp8C4H(mfWPsLVP&RxPR}DGMP(P^Dh~9ZIYWM^ZGPgTLySXVssk3P)?s%bQ!`UBVco zaQnW|;=wR_vl!4%UiQ*d`9cHVn{y8%0Alp9sFmq@oimTq^v4h{sC0D7H@TRB!a6>3 zH8%^f$BcDp5yCe9Z>q_fGRywnfxW48Ku`y>UiX(H(EO|S*7SP9@igumMKC$$QDqH? zN{fWoM|tnW6tBrxPYiBUH0kq@u^R0rG(Jnz5Z3I|MX?5IO#bMAHwgE0@HK8-z z*mWbfs20}h+B%D3KW*8I1r1-5YWJFyolP`gX|FChbK@p6X50C_c%OrS4{(wql`{E# zz_Gkak*YQ~#oIVFJWIxalrDpjtS+c(inzr+(h?8R>(S4^ABj)Pf80Fnu z6iXrNY_7~vaw+$q?ylekecAl5ii<>m-BmQS-^TGXk@@~=F_1!1&(=h-ys1q(KgDvX z@Q7c3On>XDrRa^B-FhM7Pewfr*Lvf@@tudGgK^3F1~Bxx@p5`dqZILIN3lrHDCX8- z2ir{@_%*aXHy!;WEGBHRcUg#JkdA-=K^LW!)MyI1u`QpU+|Ok*?Gh8;2!x}4myyF8 zq85H=z4DdvdBqnudlWPfQLxK5crXQ2Ix^rWHj1p(wxAa>tJ<{brKDGs z7|lvDA}D0TDnm*H7t&~lI^!@WQ%Wa1@w9=3bSTL(3mK-qFs^bDo#2z)sDo9A-&gR{ zLY8c$1iZMw-ZHpjZFyjc`MIyMsDo1+SP9_^3_F*foX|!&B{)E9jt5PL=J|AseUJ@7 zkxQv`2`b=t4FX>Di3r+;tf(3GWKBeU#KN^ZBBe+U_=9lL=u&0118Ek9$c8FI@o`hw zRY_$_yiJJ?23OK-*!QM8g*i{^D{>VL=(Qmt)1qs}hw~}BeIaoBsVCp3o0MLEk^m^h zzBTiYB9>AjOr(T1f>3|ll@zg_1+2CB>`7jejH6%Htn=Xez82RjDdj#in&tf1_BHN;9}5SME+>-{2?WaaiU2Ak4|AFjS%0^AL8npTa^cw9BV3u_-I(sxUkTo@EGvXI5(NWsk58eRBnII^+mpj3B0lQe$%d010K3pX#Oag5 zRqcW*cHg#zFRuIvgV!PmeuN1Ei-1MghZRb?L@Sop$sO>AGSc6IQ?@E^0}4fYG#M00 zQAD#SEG8WY$sn~DA6=cpMxRGRhYF0=|9J0idryK&PRJU4uulX6*dz=JsM0k>dXg+2 z=b#+EnW%~J5ExQu>`xfbdYI+y`Oz0-`WManbOi|tbd&6Yy%TSk)(v4h7M_F+n>&`! zAo*MpA)ezHnCqM+=&7`57}ydiOaYd1uQS$AKxhn9OcC-`E{`>7BYqoxn~)CP52&Ur zrnp*i6)c%-A@)5Prh?yT{!qz4FvVbS{y=R31b++d)dXz~faST}TludQ^nBZ=_#rGn zVH}aOfLJgCXNkqGH5^V_LEQrEuS?)}m563XR7o>L8A+ zc&oOD5m)TP$|}s+51*9o8rn!D;q4SOp{MqcS%aot6YmHyw$uqH;Z!2WP^!jMU}=Y# zlV;a4^@I^(Sv;!;)RV}1kk%=TCE7%4_nQ1FX%= zO!g@&CLwlf0%22-FtIN4A~)v8OGWQ{8+`pEm}VAD9LYCmMF79E3uDz5s4f(v`;G() zF<}@)!U;og;oySl=orzmB01)9>#$T;CGP+aVp-MphglE`>lXsokisl#y<4Q30smHV zs20g1&$k7lOg3G(S^?4N{M5nIFdV~Hd5FCO_K}sxVh{0q_b(|l? z3J0!4uClZfN4*6+E(@G;V{D~^EzesSMKKB{(PPYOF_=(>uVt>d!y)*LPhW8p)Uqe( zjm!&-Z`QLQiYJ;8Pl-SxR6CocFUp1FhQe*)f~QrPNk1(F` zov-IJ@fY9hRR>1Ai6i;3#6zlQX!)Gi(2+Z()ajQJF6M%q5AN#U+pm@%te`8WCV;0% z7j#Ww^49$^5EW%`P|T>IJIkk(lh5e|kd&yD<%9DF3B)1avZB6fVMVIke6FIRQ$T8S|UlLcnJ&~f41^ygZrYdS~pIWz4MW znabkgdjGoYJJEGLF5{pr8C6yoed_EnR?p>=dUWpQD&5Kgxt!SENoGjBQ!F>0Ul!L4 z`B=+-0Y)8czqJyFJz2QA^BMtaj%YDSRohICC~#NyH1Uvcs%7Zx*!yrqt~6fHYCk++cx>G-;%$Vd*9up<{9sw{Jps=OFlC2 z$K50X#)G7Arry!LVdS8)aqQ(M|AJ|_fU#R9cNY%mE)I89z)s>9~ zGVq!2Lchz3KNxdKoUG)~h8_`O#pFJO0v+|E>SH-_<3#niUvVIUtHi~KGE~*3(4AdN zvcq-V_r@j)VMF@6RpeJ6{N=9M3r+9Ny~GC-TWh%advJ5V(VUdMS}$a2X*kFGX|*k1 zU@%71!_Su1;d0)xV1m_Yyz}#PQLt)bmEYV#QM{*lDzw;6559BmO-{`#e*W(ZXGO94 z>DzV;WI^EVxdlPlqo$JLt(|=Fet7nj9z$Jk#gLK^;}ZvJ+_EE<9apZr*B~z>_L=O; znP5Vf<~nSiqB*yQ*%_G{hN;#T>is?C~yWjsSUF$itv{Udm*BU_#Un=+Q z_ib&U0OHg^MGkJvVW;|1Y#b5KT;}7fNh?FBnG|UYM zkwd9(Ghg92U}&C^L*?9$Vo6ZiV+QrqF#z0S^+(nF=+e(s<9{@dwl1zVM&S=zif*S3 zPdsppG)Co>#lKpcf#!llO1wS+HiiQy_^^+))xT(3)pVcKh>GruRsG2}AOvwCQ^t^j zwn4#MX48eVLix0#N(%T}XZwA(A${bY$|oOmhb_p`wA$6E=_Jj~_qOI$2TEKHZ(+=*rAOF( zJscWOTq{)PxCbbmmu(Y+};zmUTiiWEFVjDL*BBrjvt-O3qeykS<(_|Vh8(4k$oH% zygmI`!;boxpofu4lWXSHh?15i2a;QT&?TNoobQ6v^FDS(umC0{-8#B0w)1kxfrn$P zNp*zr*}fB^Z!46pK1{tmFrHbS`K#+nyy&dG zd=(nn#*5h1;QI_pU~+FIaAz^iaCBcT3x#m^cmcT$@`RfIp+z^Uq@b%Q+sRMt(e6fr zn8Y5zj!6BMPlw<+h@V@?-Gua0l%xVgy1-{tn`s9lAWjc+WNaiOSzPNWFcGy@Y9F)2 z%OBhv0SgAVL(}>fL#82xW;)~`jy%lv8Fwl)nG>0awIJBIKx8*#MD7C2UG{Gvx-M-ETyL;`|E>F@%IFTQ57Dl$h?;uT?WQf*&T4 z`(5B>BavEJAMSXxh1X^cmB|!-DYPEN%ZOvLc1!ct9%WG?UCkhtG&zjqMJ}cF8ujL$ zi9H6CFxf3NT|L-lcpDCgnixJDav-P6_o_3rLo>fC~X<3sCh@amCWx@ z?8)YtYvMW$9&Qf1xLG;Xr`4pWK3@Hjt@N^4;Ql2ZavyT-WrrQ~ zYe7A7r!DDO2s%2bRlOtMrOU1&?~y$+q{x$RT@s)=YFj2Cj_ou3XO@a(OmbDQY-I2- zh0(5=igt|zhL0fLTiFb&=vf_w*=3)1CllQz3H2yABbODN zBGa%I9i6hwjNM|qkh~2m3+>{X8lo+m5%WD5*PYZ>eSt{g=D9RoE$RU z-_EDpqy>g|w2BMe$<{N6Hjb0R(km|66&t=Q_qjN>E6u8%+ob`HhY%qiOdB~$O;4wE zZ#rhZ^qpz(hP&|G-#d**5e@g!Y7xBi-DG1mVHE`=jR1e?_*W}glgfzmVtg(4gr<`e z={nBAvFMs%-#eiQgKPLgJ-2YJAz@3sX!WzlwjBr6;@gZ~PPmX!SEZhHGsb;0U+2?B z^w3B`rBTHzGrI0BZTLGYWQ9{-(ReKC%Z8OdC|3)qRwEF8ymaC8^9@BwH1LEozawp` z50}?LXD4F?Y#az>@HCMPOrcSBVxWqv7-1~><4H)PkjU8^9SV^QHvXn*gQO$7ZVZAL z&w3CoFT$=$TKo38a70cq)SI;?IA-q?{!;(sWqY(xVg`;4ypNF@bDvAtF>@xfSZuWA zBf`|9-T2@ycEP-)FZB5{-}WJMaf()bz&jL*x|CM#$w z(W#KtQGa*!0omT5oR_erV~9(j7Gfb~RGD=kXMxRQp=oT6M}+MFdrq{FpbYaHv=s#= z@)xBF8cTojB|<>El(pu|QqhxBqxAz4mjb&N-ho}`)A~>@*&PST2PhjB!V%~h!3>W~ zjt`XS@f5sn?{I_JC*98-15;6akliOcnH>3#NMaDZ+g7q^8Qt1ICWP6K}sgmsgya4CVI_kMqb+wWj#G5yYs@R7voGkdG8eD}s z9-ODdp_&VMFN?t%YFWvfaX_H=3XJv;w+DY#NgIkz``Sed*{=|YJ&JLnka)}BoJ%>-O_Toe(Xe=_ZkeVYiabu? z)z8KWC_kyvK=8ElXye0xeHxu2g5}Dg0y9MnrNAce2CNH(u-}A#mNF8}^})bdm$LI@ z09!5+wXSC^dl4;%*<9juVRoLzXiCy_`MWpGa?z~g<;}&pNl&c7lOwmIB+-A>xEwYqqSI)uLZ%N^^=)`Hi1ohl8WZii2~#O* z$x_4cI@O;UP>?X_M07o({UTx@-XJ2-5#jwPe-oIZP^GA@%SHxPc1kfIq#~xCzN+Gk zHzQ@bHvqeq4 zw{~Xi4X%8KlhG&zj$)i19eRw-S_tT_e`r~Bm(-hGksIEBS&T``ozaA6q5P7hVq0-W zI>VN}v$MH8{h3rRU}MJ&RaCdglcH1$TBNgGG$>+wt~6Hmnj^cYovKj7YU9JFPnSbR z`9n>qL)Ix99w5i=eY2NZJRn9|zH;%1*<;&I)uP`54=xg(9tKV{ur~7BuZnK4j$I3R zf{hUDj|vYNV*`-}P@s_%69>*lRO#dAAg)=9+h(b2$L3Pu1^i<*# zF&z4SO2Y(ATVf0r5hg)6nu`x;uz4kvBhI4-d=kEjtse1ol26Sf(8?4FO~a zXnNX$oefS5Tne%}Lagy%P{fn~FfLA8-Y6e)v*3p<2~c{|Za3aWm%FYrU~RMR7Oei} zjhFj%S}$g#RJOx^`-xpT6^lF9BhuB@(r>NI#$d1dI^#smGA}!6HJpiR8|$v+i-OQZ zNgWr$82d2pBv^ui$m!vtx5ENW@Whjp3!Nu~&?Ku|o-H(-F{yz$4d4ff5QN3k#IPKw z&8=1bva%*C9>6)&?TraYSfee;PzI8gI8>Qf(RyYQ>x|T1c?Jmx_Uq!so|$bkRApuR zT%EtUv|KG)^ZEG5@YbzjMh5BWi*5o|f+TDNiv-*1jx-b|3kP^fsq14xgPyMyNx zdLUuo7s{KtH@pAn5`jT`*gC|)EB2E#jfL3;&%Wj~%othCS&V`GFKPu?ARcAPHR$Z7mdGxEEuDVKCE93`SjCmZYDnNf_P>>(VMZ zi~}Wj3}as5_6@8oIEMsoWTOxh@IjQKaXcKI4qSBp$l#KGc#u%QBD+tGrkP$DJSOu) z$B!d<`?@Z6%2c)|btFYVWyThz({@#BNwVwF=UV!kOXM|;>#&Vyp|^uuR!n-o+R)UT z1Ph2YJ86WcnsljtnuProX-}sczYJ|0x!h_R%48Yz1BKzf5k=tvm?n5JA}Pw*frl3r zaU?KN5`-OaEpY^KZ5lh=_cbbAY(q3gX~NRJ&ed&0E@j`1uQ@l*V0&`x{j%z%2)(}H zD4Xr7^2KYF;MnGAkYi*vlJl~TY)E6cOhP||xr#2;!5j-AzBfs;*QmOPQS5G}PGf+G zf|)&mGSc#Fnq$6{hL)s4L_(-IiWSU3IB6khFH8cP2~{)*wRn$Fg}0HAZ4iG)+`I|& ztgUK)s~j5BY0ZsyAUDs30e<9xvt=0uKnEJfx6m0_GGA3seO7jgABG$shT25#5cDqKHuj8$R~i`)y)**q%6vC!=pMS*WaovI1oLR znXC?Lb8W>1uKc1{wqCB_akGz_H6&10&Q_Xv$Gy zis!_Ycra&3=_%RTTH9ro2pr(^$MQgQ_uUAG$9D&G)p^urj>cMK&>p!ZSH1Kk0&L7M z7Ff!V)e*|1f;fP5nk9_&5dnQ%lAb1{N_g-dqqzWh5P6mqB6sR?tbHnqg)==2bV!qE*7P9}RuX)%Rqz*#`0=2OD5aemg@RAsE8(8r|%YLS!(R@E=) zePd>BJSx!KDlapo_1et=#L~ZA&28Y9vF4#@dHk`%!SB49B+oG?d#aUb=!oL5fZ=~; zVFPnWYWc-nYUPcIi>Ps{XcqgZlqUFSbG8zu8`Mt%cxUwNLda>Bm>FDi?u*Zyyc%v^ zRO~t(n<1lb8ftTV4%1gQPnP~)(|*9bEJy2zThqP9!C(16@2Y>w!58q_mHB#fzA3r# zugMm?f_n{R|C`zMxr-v^{qVRKnJwW1%+r0-JsiNaeXekE>3;s-$JXwecsY6Pslvx- zAhh`*xuIMjugZ?krGrP{d){Ego>3d$H(yrqf&W7FG!X$s&)>jcUUKlAymm2caNr@% zWjAmB=lB#@d$yS8s=e;oysCB@?FD9BpZ2$02|Ra?CJt;WZfuhD{&V~ur{3&C0CI}o zh4=f<@z>`$Ykl?c*9!U9%c=8!AKmy4o`!!$`%vD=C#&N9!s%An=8A@(>_f2S>6i5; zfM=)U--pf1t;fymm1o`$UgoQ4AB3mw>3*#eypaHJ3m^DM)%xN0(biDl@YJQsGxL7<==AhgW&!!*(_%D62 zfsV5!1@p7QJfKBs@C*8!X^7|N&(6+R?ljmFQ`xwk0kLM&`puI84V|U^`n-$NyK5?a zyl~#5q5ZwExaM4VQvp9VpF9%UevHIJD@j1*jkUqQ9}tw@wGnLf>+h9B{c|G)Q9xJ% zC1_ZiM;r3U0GKH_u>RoLy=3iX@?o;Ca6ANsOf1Pz!Db*@8~XlB@#{*4SM`G-bny~Q z&FhSEc2a0=%Kbc7yf|1ZZ`8WIP|%IU;m;bNzn$x4bF`ZF1dh_L!kSfBr~hr3g4x7^ zv;qu4O2N@D%9wCL@<7(;#f#79d%6C>IJ&{EWYwUnU%1xPmETM!ZplF+__sQQ*y(zG zc+Y9137fTMylpQ^`H1tFMa6o!RTSy>5*D1)D_ei89nBA;URk4SK8g|eeoDqx&j;G z9u;@>Cq*Br=a%zgLHE0?1-8Zq4#+%x6s*k)f9(pDyePeF^?ry8y!L)4wPpcMZ#NeV zmwsx!nZPO>{POMEy@L&-?=FeWeNni5c_)}3cbde3q{CX)3~VqD1e;&CyV)HdJh^@z zS2aI=MY7NSkCe^jgE`uX-_vDa$5Xf0(^fXYgMimJBOG5$_Wk{6vKrLJiSxlaRa4aHSK#sxPhQQ@P1G3^6W}TIQ;g`K z1$}XoRpAEnV+xt*Q{Wt~2THeRaScFBw?rhQ;J0wZu$aV?OD}#}toEo)J{rc|MvE9( z4%u8=lM0f;e{U1#g%X_;kdgu=6KImr0~grAM+1WDnq!F~6F?#W9fOgm&vT@70KJA% zkUkUCZw#Tn@^7wBY47EN#zLz~S=5JOR2(iErid*r#BJ87^e}0&8IxP#TDG=#Ou%;? z&c1`13v?|i0yC6;q$7n2`$ZVoTlXhM0?kT1sc^u-Hn^Sb~G-FM1|yBofqQR+WFx6Sy^}tuXt90J!!3Qf@Tre%wID zAki3d)sS9d>9aJjT#In$RL?tr%6jkhu>!ncf zJsBbfXhzg&2>lw@GswMltW8A=6=tTmR1-1YGtCse?BXm!bY^g*mC)!A$|Z5poXQiF zd0m7;WWRT)frSZwRxeRg1UJAq!oprJ=dUgnX#SDmnA#<^X%*uK)&NC81|=i>4?f>c zum^>sLxIT3j2mJ;VuWXF{rL}{f97)#KpWeSm+aZo_uQjIT1#m4F^Yu%HHt> z#YY%gWQh_fBj;%`pUY5+U4V=ea!1h$efV^*#`Y z1S-$6%+E>w<2f6Fu?FWmei}&o+oTVH9cO!|<8U$Az`tVckaj@sTVdTsqJ&UROaXWpi z2%gOpZJDtG|8uA*8(%wLuUZ!W$R+J5->r~zcLl=l;6D(3!%iZ3Dc8gau|3D++VB10 zP|@vsN35gU#QHsc@Yuhj%3u06x|Re&98K=wB>@srUN`c?@EpT!yGQ`@!LcF*b`0FIPfmadK^HqRlUrM zl%nByUpB}H!t)c1@RJa$0uWsG)HoAyFQ|jH4}O#-k4h_z>iITaX<-ytGyaQnbNrI` zfzYo#m6!Dba18#KNF%N{y4&XCq|n6$4oC;|(&*72pC7{fC!R+NXTZ1|F2`WZm2Dpr zWB@@?ZKeFua#5#_*^@mVJXzKf1A6v0vZ zl2-hBlf-6^nl)W{L$ZKy3nzAIxph;M{wDVM+dPLGcZF!c?heN=5GiP`*u zXpBOBj^9U88%QBfvGh9CE>*bex6svOJyI$3st$`S{?+fNlC^QZCUob|nT!n#!ju_O ze&)uSL|m7X)3I=mYD2TWpM`&C5Mbnkgv_`b{x4B zunZ>4=0%vBs-ChcnP)fEfHH&h{cburmK<(#wHPcDO}n+?mxPx%y7EQ_Jj|o zd1{x|1dWZQB!nTy!t;=k$H`l6^=pw?H`BwKY+Xv*U#`4Z_(^8+ZxT(@2@wf?Ud;IN z=gyy=;qba_DJTJLfb`#;DgEwmED4_fxVfNw*yDe5bIJeV<{PNyo(!^&c&mPQr_1Yp z0lDmo%@7}}O7i8K34!U8FAu*2+`LM>Vlmv@{XNir0D-+{vlWG#=@-5mJ@Z4Pmw`JI z0e>9`0_sY9#Je}Pe6Npt)4dm+`s=cu#$Fwec1TnxzxNyOox$*))ycAOqnXrmW)98< ziBtV<=zF*ujwPU7(qK{Kf|h0M_0IZ3ea~$_f1_DfuEnwxxx*lbL2PBSv9Cf|fs@L5 z;+?QUit1jWf|n$sC#CGd-sn0fEFPAOcdJsJx|jo#@f%Xd1^iSR>>JK$Q4Tb13{R=m z7$fvHM4{9-$`cO#-_`f6liDV4Ui%rO5g;v{IEgp7@H!kgVL+W7 zN=OcLIE^IETLvABJ!p+bl8Bixw6G)w@+00|_4=dxV0;JiQMVL(k)eMbJL`0$XD8yu4+0KHvhjTIbU{}HgMm1zSr=r=jMjrdagKd zUtA$LZ5cz=MP1?zEzdF0rwV%6Wo3c zpr)i?$uQzr^LUUAA9YjfXLGHFg_H;6b6UNu&b>-SD`944 zpsPeZFgaL}dnnWzy~_I6&?g$9BU_m_^y&};147Iu|B}>N2~b=WB*xOS@qXE9@Pie+ z@9xIqn6yqXp&o{3mdvmoe3YJ8H>f+=;tc=4+j;i$zuWnVq?3FuhLpspxe@dzH`lu| z^$7#PCLlGN!xj^q?0`v|mL5Wd0`=$AxhI2Q<$t<)Ov|^MTOp2Tc3*(Iu`~WO)f=O_ z=i`E_ZTwkRSmSG;E(hV`SMFhF>E~$s0rJ&du-ID-OE3UPG^2m~efjZqdVB!(=Br4$p6H{XVyK zvW1A~C~@;7&>sYrFQmb#DoO?b3ANVL`;5z15-*!AeEtP{I3d~mGXbP6Ni;$B|EY!)t~+P6fI0xTgyTEdSY0_GOUPX)1C@KA9lvre4t8 z`c4;FXdRy|{KozL(#!a*;%jWMJp@t#^Djdh1hRh0$HGM`HYk^F``!&gY72^TSD2Q* zb7&fNYXS<2{t2F@iOn*-36Z^$@obfQ9qZ5y@$c%SSz_xnbKrf6s877E3B#Y#dvsn% zXtM!RXXijh0)v*B11!ZpI+wECRHxbg3ONv*+G>6ojoSZF{s`rOCw8jdtO;G><`f|DZT%l4t5SimxTdxti}jEfs6i z5ALDSaCCRu5iu0D1{;B%EaSJP+{CS^?=QCd(7Wp-mvz3s?LhP!FSGAlu%z9v2yj1~ zM)Zp!l^v8mH8gV=wcs47%jGS6L=ZEnY>+gHlKDda(Gg~U-nWo+PS2q$(y;*YhtSCf zG!~i;pXpAwo$$MEamnyFr#asR#%tp_VTh}Vq-h3#xyuJw&_oHX*&jeblLUps+u%`& zU~zCCrTjDv!gs3!(sY)af7nv5-?_&oEGE6+lt{f2kk^#TNRrvwC+sRnV9seIb*C&R z?MjWtvALpW$X7VyfxV`vQ{DH;Q)p2wh;yBvq2MuQ!atF>vJwNai^gT8mK^_ulN>ar z7R}pa0e~RA)E^f!X^goc62n|AP+UcQmkiiv&t$DHz(Q@)GYn+-|CRC$+JB_{8Hy3> zzocBw$U9fWx}pEG0&?2+q5feAb0haqw8{&cXLEOaMYAKa?N!x`V=ozu)moga9#o}$ zP94QK*v=K=GDQ5)^Ov+jQQ`2S&S*eMT^Z+$;y?vfyoIJ;nJ<-2Ej8o1x>{~Yq>ge~ zRqPSq+q6#uTfX-MXP}Xw`Jmi!WdXE|K`6Hdo4ygyQCd|d9`}1>(D=_v3vDI~h}*lA zBrD$kh(|a|X%Gs*%2Yrph;k;H;4E+2%@VU4vQpv(Ucaqk#iTf1oK#ciPike7P7A0UtW+dG9UjfoD8E|48|p-j$Am5F;5hOU~f0gsT`6mz`&|^ zYG~V-=|?dlEGP@}VuXR2!obIx$)f&oTOGOKF_;HkP=2P;{H+y3HH>h3gVwAhA1lJf zc5hG#`8_y*!p{?g39+uu*bX_EK}~iO=6nXU6p^sL@umcZ?HlmzOCU?w?Ed z)JG;g*F@gD%-VISrbq7N|HRxZ`vlSw+YAJNU=qQuFyUi8@B4kb-G1-6enJ@DkXQ;j+=H>gw1}`OPA#X{T(;d(68g|<|ph|zr zqI_fH72w^1Y89A7{k+icJesCL~VaBo%I9j$l`=vKo3wPZ712%d)- ztTGXV5TPNaSmVxfn|{A7kqvN_gJ@Hxq}ZcYZ5$1$TI;rNeS#kR`VYQAw}NJxC# z4n)!q4Hk2p?7ttOle_~*Kbv93nyHu&M45u21)7y)uV02Z3xwk;ZA{!FB%G9&#!l@Y zjn&Vdp9G{6Egc0LV~Mz1bo?{-IRX&^$%eXna#}1$=mcRXpFYKiS|~yU18S7Rfq5uM zz8p6qDh$C$HfZ~n@yEEN6(yq8uRN1A(=!f#Q&o>)!o5ifdZ<4TW;pU5)!`9Dg8qz_ z_CrwI<2S~Lhpb>Spx$^%VHJg-pvO5ZfxQkR&W9UFd%>4%iBx5=4Z;(bC_ zL0xvt@LdHi1H7^ZtPdOyMKM?=oFR`9WYXecHJmWT+uS2*pgfjVrx67xm;C61j;8ef z5N$E>@2eBLP8Ucu*}26f;N}Yr!|Xmu%NDIxBOGjom_aS9OeAcA-TvCB#iuE?)IwXl zF?y71I#WWlAOtI-{ylZA2qT+D!ZfQMCgE~dNqtkHS~alYBtu)~-}VX@2X|~SCg*Jm z7u1DS5^HmjI`F5%Qgn_Wn*X5Tg(%-NybuMq`1zT2QngIvn}R2|UTC}{{zx^&sL*WT zm@xPKFx&TvOpa-}$v zYWb*Ubv}&HtSGxN0hltd77ZaSM+7G5@J!t@J4HBXuR3j3f5KlheDIrwD?5TNEt}hF zM_He{o1YmQeg9}N*47LmHmy$jtN)jK8{fbO-K0F z2XMEUJ$ykuvqOD+Z5WCu@qZME`XIE%i6#(`GJexD`vl^pIN&JA#?LZ9e^2Bs?v(cO zX_tZIWw4-xvcupSU>OXQ=hZ3X&rK_f#xo5JMo{^tges^r<-;Uo4K<}y?cm!e?F%v+ zFA=>%&c^M!YxA)>S{$4&iw}$1N*bGd=*G;S`aUm9zQM&{<7?f};SwuqrTNjL{w)$` zH~())96JgdU2A7shVt)`cp4%$@-BW1TyegiDGFAZ3XSXxo>uu(NMwA}Uq~EVeZ_W5 zl=5@TF=8WBmG&EnM<_YxCpXT!_`w!VGX&NKLXK@~LLgvJA#&Q%h&qT1M&bguNF&wFHAP!VFoBSPS?)2; zDq8O3ve!x)Nd?7dllN>XV*plKjmOtz0Im;aQAqR(6vvrG(%@iA$3Y{;{>8)vxmUlL zxI+9l6BiTVq`WN$(@JURIDrYX!f@zi%Sl!b$OfH{Y=mr841hobl-w1ErZ=Pp0yx0q zEL1muAuku9CN`VJC&nWbj)cG|AapsZ6VtL5jAuk$7yDCO%csNyhaf$D0{+yK!rhutZo1)+{fiYhAs+MVl5GN zvK0IXr%zahq~H)x_0IJO6N&g^*uzxZiwtZWSpad~4lA_F?8LlF>zHJy3f$7< zCGUomw(_v-6TocD#*ne$6e~q#Jj}y+c~kBfJAds5nmTCtf3q!ye6qdvUMdft1OQBOw6y z3()xIEd5$+yZ=0F(bbR&M5;4~@80(*{N z6FT-ZtWZeKw>qDmcVh9@zdk#MZH}1OQWZ)-t4bN?l82*pH$0vV2R)t-yy(QC_4##= zjx0nM>7_GyPAoPoC^7Hv zuj3otgWI{;E4H=oIVNuZZs5KOfIhPYH*~w$z$U^``sLS%C;Nk)do~a-p-I&1269nx z2IOGPP$>C;!S$N0!34s5h->hWca(fW;_(4(u}?o;^o9NbHK@Racxxen@-lmdX;I58 zmNY8l&>kX^L6~WHdU+>2%YgSfT3Lx=j_trgBrTc(_DY&LZ2~AC*B0Pj?keD3c(8z6 zW_00r68_W1<`AnW3y_X*06+cScVIH&$Ft6!jI!hu1o0?8V}i*jzf9sPzP6t<{MSSU z0k{yfbG(!Y<6ShWT>Ol8Cp|s~M+|?+dsB)jjqN<^N^+%-elebJ{0%1)t>h~EI{r+B zzgoZ8dU+r7@>LP|-gBeXY~R!sm=#epASs>ZLdd_USo**T>(u>;7fkJd&pdXKR5WJ-P^|cre&9(HHy2G9O91f8(C%j0}O`#hN*10=#Xx zp;Mrb>VxwOh14DN?#T}TDF3+q#-oqkFO)_&Gof085BUx0mm1ImWtuMJtksV;(7a4( zx!W!U9`R`Xaxq6{uai)`={2HFb8eo*v7-RA-Vz_mJ>G^}x_#d&TE31h*m~D| zecy)NzP9N=?0i2ik3Nsqe7)X6Te^e0w>sXwON`#iryjZfd|h3A-fT>5Pi}$HNcx^2 zPPKi;BlfJS%j%n!u!5LUAlPc1ij5Q%t<=B#ZgZOg$19o=dq6i`ZIIYyT7uQHrFavW zTQ&w*!){V6!7r1k5W59tvCRHN$y6~YR$Hw`rQ#nX4Q{tkm^ddTK|ORLAYrqg+FyTk zf>s~uR8`7uG^XdyT^%=`{H0${?lU8#n^}H93L~0$M|o*$eZvOQ9VK@V$yZ*tthI5T z-~iUG_?J6vE-ROkLb}&m=AfU?)jwa&Mq$_nqE^wJW<<2M2>0MpgoAE%A1HsoxPYi3 zHJd;^1T@1yZ*8W}^f6{ZpvN)H3Va5gCCPSmRAdV!(@dviv}%m+t4(`4OtSWRnR?}O zbBVwC0aHo!-QYpr^aaKCxx2yF{Q+j{{gj(uwAJx(xZDkfg%4`?C1x1@MMV4w#pt_d zb=%!x^Z8#kc&O!1Y zYZe&t{=UIS!sGcA%TM#^R*p)u7XH(U9OZK>bryQ_b1UelpK>0GUQbQlbWkb(DE`*R zUHjMVCAvgOQ1d$#@fW*B@uNw0%;qQEZy2QKn(LjhcaOU8?%QaX?NGW|sR`fU&!YOb zQp55%p6k6=nblIg?ze-rEfrLALhxyP4o2Wa%Ie`#(JLf#{y;pred^$8#%d4PrLhZ} zyStMzO(*0{n#}oAu=ZZ_9ZzS;_i#!F?|6Oxp$eE&ys|$1duvr4v=Q!^&RMOQ)J^Gn zTK`Biz|k5Y9|muB?mJfKhTrZ=iRph*xke*#HWe~r^w4xdYsMbU=_0#cl3%nexpSrt zw}DdkYzED-e`Zfm(N3L|y>qccLiKhK)!>W0#JYCXM$J}f(pjt=>k#4%s^eCX8vC~y z4jz!>QpUu8a(+Hc`NPL2Vr15X(3aA!*P?13~Lm_;6qLWE?G^R+dIw)v|3Q1CpF z!cw_j29;|YT3;3bdMKCo4+M-Ek6)B|TVlH1v1qS4wC*C6)hHNqDHsz$q&Vc=|Bs4% z`uJk)@@m{hM45)yxV6kcC5vveM5DD$rL|5`C0Gv)f76XoBR-R5xam9+8+;QXA?Tj8 z6K!#LuaGO&IohE^`0uN@ld?0T!~!RIcW4jG&AA z_zt)}S3mN=nPh^Ks~isNp{;1l5x8q^bTiJ`H>Fdh7*P$bE0C?3ZsVl^0G=) zZbK2yqpE0FqjE9 z?QlB}*Q_OL3!f%xTG%dzM9mae3b6k}fxIkH0V|C|DM(yPs(>+=2368ekH+mRY)>8S zo||P39K9TV_KmKOhUA6I4x;>}S@QezPf_X-&Ay*sP>_R4K;k4w_>X~zAvYTm`!qmX zgF(+v^UT%clgdV;Z|20A$m26ZCG^LQ=qCms@Th2U-L?}DZT+xC`usu>X4QvqOq0O) z0`lnvC;61l@qxby`^4iM8o7IKFbOe@0S1u}Kq{fAJ<86X1aXl%=E;J%@-X?Yv}VY< z-XP>s2v;BxS@RW!;tEam)g*Qn92I9y%iroslL=D3^Y+6e^wu&K2V$BT{?yjs_18q8 zi~+6DxCQh2(e}dSj@pCEjKV}GLD7KqAid)K-AE;vvq@q|(8V2Zh7QniRcMcB=FL`B ztq~+;WAO|Jg1C;@AwQdNJ%bU#I&gUpEY802XeX?>448oxY5imK|Av zvQ6PlOcL72zF%&>H(&m5bbZ$S!}`nl{*NB);gn6B3ZijoC#a(_5GWJjAH1OqTphe) zNg2yhYZ`em)gTZ))yf74En^JEKQqfeu5G{Vg>Ex}mtjxLrA5hWLZc{_TG#>RIPN^c zdHgB-Uo7fNq*p-8#heX57a8}aH0~-`@)O;laURj#7-54+Ouw85YGI=J7qN%|s)(Us z*<{6qvj(UQ*A*v)Ff956h7@zq* zUvFzS_VghV?<6#6aszU2_RF^%Q&Tm)Kjclz8uW%yF?95*)GYWbbsxRD)z#u5jR`rc zD?wOQ=AlrR=D)DA&g*w`v+`bI<=yOGoZG3)HXt zL?d096Qs(~>Ulh(AA*+V$R!m|CcS@5)tDOs(@Sl)Z%f_qIQ4&UBO zR>m33oTVD``W0M!!i3ShedW}fMYd2vA(xVxvv`nTdqA_O<{4Yg*IO|EZ&Lau?EhU# z&+#a8rm~nOG+XUBSED&{SNy}C(|CBdK<#Ln`>+aac|J4;YKI-AIwkj_2zTgl+1T4z zOtkjndeGQLC|L4B=`1>xrPGn=aj6kl->f@br`p}#U4V9JEo;w471BYfBd`j>z4mF8 z@5JQU?3Ebtn(xiB#?w|dL)AyV9R6Lho7^cEWq>=K3p}tRV$|jBw=H3&lx$@{0=Z*9Ib1NU(lYyfYb|Ke41@(*1qBJAFq!)qh3cTFX?$wjjZuIF5U**J~8oUvF zIg1JP^#m+$suSC&7#TR+lDxh5FQWwQUuCE%&bRF1TSWH~n`(U1RcFP@nz}K|RgDQn3e% z6=TUoyZvtj^^0#o9sY2Ps`JXY37x|tH@3mjv$*T)!kwOzd@AQL-ZGa2mE`Num@{Yj zrf$Lr8_f9&D{+!rrvM2&|HXUwCf5+59pS1{O6 zj~5@trZ;V)JVt2b3oOA=AEuCDcVr~dm=S?c2}*q3bRRzNOEu_H`FnjQBBU_fB9?m84Y9ilf!lqub@a>Fb)}%MsQCceG}u@$gB(kb_NKDI~bu z)4T6l(9Ikd+PaBOyDEKW$7L0e!--5gc#pMvj219QGC!^@Sf`4ATP)iBHEN(P`dyoY zd5e#pNgw-KBLPMh2{gJ21XmgV{z+L=+CTzrirL&QZ>SYEdK}G`N`~SlpeN_)(}Df+ z)!U!d6WylP%@xk7fe@)B$zl>nSebRNHm~1QQBw@O#uxk5COpqz1?!ZSPe_c>db%iE zZ5v5!NP8JuI`U>N!4%%#zIx96uw*waHHejc{b943E)^w6M?L+zG3TRLpS1rn;J!FZ zqg)O*55%`F&HnP>k#Hs8dHg6ff_H@P5$b|6rm#9vz-F&JE zLn})P;PWl2196j;dck)+PhQ|K0*i}heUDLZJsNUhW8{6m?t}80(}9+^e?liwq(_jP zD1gszx;!>H&JBlGq6Y`$+sap8bNCjHeWCKij=_!HYtDxm4R0{L9l;TlkfXYO>O4ZC z^~KAH9XoV)W1i>rwxHstjO0T=4!e24a#&^2+6yiptw+SQ@wQ_?J0;W&=J;)@Q$9*r zew*qw@elvqRL95uhp7&w^$%0M^5?gy9_z{$!McUH9oo!(oU9UaE&>J(sLWhXS<7s^ z_7wWmO9MjCy`GR9&q4*CdIe5KrvETRC;J2hO^!j2!s^sNJRJsw!MqXrZnhfji9R3B8w7qAPKSkM=EP8G~rQ>n&C zbC(4?b3SG!uVH1?6+|7{;+?VptAVz#4(4_WADxR=qS2*m>buAD`k&PO>?i7_Yp*LF z+v>2Z=%^<7NrYIsEiu`~iX#!Rc2xT1Jr5%;(*^_6L<@$^r0ku`@M!f^#Y#i1>ytnm z6x<1HZ`dYdT31;OTDS{E0zYIl#N1!Z-LY-qFvuoF@0+=MCi_&>pZ&$$eF@f7;uPz$ zK>vfeLoS&C=2|nY8`s-ZcGXqh7-QaTF*fQz2_DUq5u@ouqNx4DLx)=tnWy{q&};QP z3QJo;{_@bVt-r?-`dGeJ zT{7h7PiC&%XGjQL$7*&dG4tX-Ocz=O?-3t}#}F5G+x%5c%i{!5Q7acS@|3q$~(PoKr zUPI%x1Q?O6kQ%;KS}lqDp}c1rEII2qEJ%`HZ$ltwv)T?2p1R&8k6CK;Gi;{$4OP-h znGf{m+RuJL*LoeoO=w$=!BKh{i>TzpbqX3IGMY%3Xd+@FTYrLJO-D(r`A&;4@P!~O^+ZgFtwUHy{GCu z>5;#!vw4|X2?&m4gyv)-H4Lep+$|7Kgu6$Z8Rfj*sVe84#sN!mO{MJC>yaC~7Jj1- z3p=*5m<4pvIh=I2t9Wbpp8A0yh2kqZBb*lCtUB3L=pD0KfL|(qIn{cS4{E8Hg7d=< z(76E(0--1w@^A&wHUv`mh1KhS=;~?h?84Ie;VcpUVd}lG(GUfbRUqXmr5sH-%nLAz zBgZuZC4@@a!7^&FGTBnE3_^3W;cxoe&Mc8~_*C38e<+0stNIX1!2b(VUHLCleIj2~ zyaO;#v)%<^L16xkbGzC>;q>3RRjnhGx1}e8A6X zm19tlOeLsygqVQ@=#biwRWU#6V@6at4Z*?y6fA^{&A;!laE9&sSP3YGWNp5#!_fE~ zF0!rU&+i!n1=u(27UAKIJpBAr|L)kEKVh>KZ8Z>||LLhiK>ZJ%x-^4(F-)2Mzj*3j zh7rlvEtH=ng7W4vj(d9(H!cT^INld1T!u{KoNpuUK{#2i%}mA+Q>LFVkti zf33AQ<8ee#z31pLtR6uueDtjiSxckrvNR(K>NlOW;d$^hoDcpHOtFTLK!D^XwHv_? z+sDAE^xL5ue=p2BZGCc{GBHD&s?-v!G&^;6StwW9dXZg7|798E)lKK^P254;l9??b zxR@ppFi81cQ&gHorJfqZad(bTVz~f zkVlkO7TI>cAfs!w`3tLnjFI*ZC99!FlA-kB1Gx&MzBSy{;O660t&5g2y5 zb6F3l12kYAe}a~AxcCnJ5j&wN(0g~tB&>KZb`J7`0@cTPz5Mae6%0i({iYdDIW=oV zv$MqG;^srAmEDC-`>lZM!_ehJ3;Lf(?B?@{{P3eZ4M_WYoHy)qpzA6|t(a;cyI%aD z&v*JDO%r-Jw6q`bJu5m{Sktz(B6PG+lj!&^T zD6IfbB)5=lnmOWko#o{|D^$3e3zYA;rLlMt6utYs!Q1&qL2`MnhEFB|es~ls5_YX| z8Dw-kp5~X2^s}pqkN_fyjZTFwmKA;1iVmjiTtf9dgn3GtS)B@p)J5`mHGbBNz@_T3 zutv7YDpmDJ&$VOYY+pk8=NPizueU?9{V_Wdz-t&kDTgX%0%DMzVntf|$}G1O{S$x) z1S49_Xpg*Yb#B!tgOl$vFd#impxR9^6=c8LL+Z1aC9bHo;}`HaMloykwL|x} zbZv(LdI21*)B=1Eb$y6fq%p&S8Ft__6L=?czXzQ3AM^((!1Vr13xZe>RUCoz)Q$&* z48(qd0rQB2R$v*42%3_=W+ydBVAXrBr}}{xIn(C2^*aNZGr_63Emi7)i!_AU)jnQ0 zdNm(r)dN>-Sjfum{H{MMeh@O&l=lEi?XU~3 z#*3HBQD`lblcX8{;T)tu8sZS6V`B-Mw*)BJ#wVyPLSeV4(DT{l9i`|U zmGqC>G%s9sZBmtOd|(4agHr%LvP;=bNj`qCh5+a@?x8zq zjR2T$Qx@ZEglQEB^t1q@GCRiF2el6Ga6v5>SC%M*_{A3lf#GljafTc>RY6$e08b~l zyC*XDVeUDPqQWok@HZmITZU~=i~0?~N$m&j`Ke1fT48{A!5E{-qNiDX9BqS~;Vz6# zLjDTTcT(>g9a3)ys#9H}HaK&G7iDsNExo{Q3ihMJHh=&b2Cyf|DxKAoVMYhAQ)h?W z41wn7O{bS5k7Ve{oRh>Jk>Tu1EfA-DLJJTmhJ50lX;DdFKMWOa6jwhM{8w^Vv zS8^K}35Zz5kdUw4mJmQ5Jus8NpaB9CuZP>k0U#p)Vc+Jb2uEmTA}9=tGMG#ugtl6? zP`@(o5`{5XkO_5}3rL2oDFHRAs?E4WX(e*!nPpOw3a^gct(KAZkws5+9@` zQl8B0*IXF|pw9doV$!{}I4AV@zI{fY%HC1;C{=N>{275>-ruaIw z{;iOxWSH7r>mWv1VcVopMVj&z2D;_WM8MCGY4ITxX))BA*9>9)QjlQ?0JvxX7XiS= zznqX+8Q2Uu3)`YwAtQ6F*YO^GB}9Y-D|2AcsU9;-Ln zZh9X+wshK6e5Nf|?h^6ZcimN3_pW>O9+9qZj#8eM^BzJ2l^%t!#}x&c-_aX)Cq*Y3 zj|4SG!UnbZw|9sY$khvJTCyPX3wl@yH9@v?CxCOa!K~`J@dB}Bj=o}|EoOMKvJcs! z0_!%}X!IC#e?Z1(@PR~2Z)O}t=S5MX5tKxv?5n3B9VbDvhuuTl1_Q8BxYL38jmiMz zf)Ug*q6kv9H_+Ge6T8RZriX^w>_J0amVer|gUsX~zkW_=aUtt%;=SFQb6|LglY6p=*DU??;D3O&9TgSDo5$Qi zImZNnHQC7*eU@zHBw*gAT{E0){TrD`*ooSMX<$?m_v4QwyzFc=e9IWuv!|`qvCR#d zw2kx$QNkA6bKR9OpSQ`+w?swo;lpFwE$14)+s%#6jIMMPpzZ`~2K;qn_SRo^o2#7+ ztZZhj4f#WTCk{-0`ITZ8{j0OyuI`W%xS7Cd1ZJ(K$NM5(JXRyODixT9frCqcIWe3H zUDR4}Tj`pBv=P2P!4@HJTd}Fu=m%FO;6JZ3Kiul6+FM+=R=PQxZo=y`->x?N1iEh@ zy_S4@oqqisT43ezPtT<0iI=#fS9Nc9X8t*c)3{21wmz@_NGrOs3-{GF&wRI%uoAlB zXXnjXqo$7uFWA;<$!Yd>=OTPp>@K-Z)0-qitEx|trAF1nK|H0R z%JX@gz@Ej;&U1OvGsz@k2<}B99uc(yZ{o|}M*6J=>TcWfGmfdNhdxH{W)+zd7fax< zJahZThxXu_pnj|`aI;BcMW8^lIHp?;3H|nUPNffr=7DuWHT?{q-7ri?DUNv0YTm73d*eXm3l&H(v;c2kJ;5V~7b1PcG`i~rw1K2&#M?4XTpNN2PIX!eH9pK?@>Oo7$ zJQOwQRHw|0*9*ve&il3D32pV0o%Bxfwa0SNVP#)&$#LtJMz<^B!oI;puMDm+LFt zTx9Uk*Ag~x^ow^^xA2aL`gi0o><#nh11`$eh}wvv z4t^8oS4fQjux}t=`DD#d<}))(Js`efvV_%1?sRU>Wfw*b>HxNdw%+~gedU|X(OZPO z5knewn(SNc37+ZWa-(+F=dvaK7C4!zsSWRMQ_bu@A$ShVN4FK>I!yV8j+X^IG4fWo z=yNWz)C?&R{H5y~+m|vsdk*Z36TRove5^Oj6^Qww zK@wvVSr#vi(&(=~ZZw~5jvO^#hfs8zc8aKLAtuc~|HE#KaKGzfBD3{{K2LWM^+;OJizb zZSv2BAzB+_7k6j?K#&JO000ma0000LWmo|4qwhtblkd-8-xnGaw%BY4U1t;!2bLQ3 z*+pf3cra@=QJkuVBNzD$NT!x#A@LP7-5M(JjAJwfS%@hJ>r>!d@i?86>O(* z>v|Wb-=cVtA1r&kSxEnm{o$V2Db{Vaks|i@T1IYL6P}ZKG+6wiD%PW_MhloqKUbE zch@e@XppuG1}1gGZ3hmTv7hP>!=CRYB*44Mcq$0LGRl6*C~sKWTy3{!E})WxxI6r^ z+*nx|*1NjAz%a>0_Vr7z5)n-BOFYtKKS%=@EwAN(965-ob6>7f5gn-hW(mp z<_jD_=DEAOHoS!?s^N#9#0#bCQ@cLV4$pX6$2t|X^sL0U&(5?(?(I?A@tWTl9o-Xu zfGFET41}7%Xo-dx5+{#cmUm2GJ0lk`wvq-*Vt0&VXe|Z>Z=4F+H!|9H|ENsmsmYBz z@*kGdcVa@@vXbDsUQq6fJl8Ky@PfMsaj@_ymh=$|pWD`#^9kkdg!~G@ow_1>7gUYk zOoMJx({}^pdW1QNts!VVN-Vv`Z2m*+;Z)JEwmO`>vBp)^4`+L2-SpV9c1+c{sBYuj zKl_y-QaY+ai}|laBk}?Qmd+EEjC`(z|mb{kmT2KIkF9PVt zA3WO0FDO(sphyUOfVAp#%%v=91%N6%wBFStRLm+X&xoU`EG0{16!+>sj+L?(n(ho2 zVjk$hUI2Tj9}Zc86wKP`PRUV7w5#p&5e_ciJM z)MjAVXpf9ZC_S?zBUOENzgDc6B}^xmw7U3cFY$n?xpr`VXNfS2{hFz>&^%$2b)rV%1QQ~Prc?(S|SfHmO zVaU0gx~txS@cQ@_(%~LAh2r0=w9*-;MDp{Hkd3jy&+LV$sW$!GNN5hctGA>H{DVv) z6IlSPtMgW#aaP4LJ4p=&T%q<;0EEQ>xv96UDv;7Ivt$`qYr@!Uw#;ZW34uc4I*ihq zSX*T3I_>u#l!vFmPBHzK$AMIEUm6b2NSF4I`r$3hPH8Md!+!7fNN243Lj2n&5w+!m zL6*xPeRGoN0yV?bCG?iOKwcWo&kzu_uYgFkj9Rb)TEM@i%BZ7Wg39k$ws=7AbK2v0eDPH2K^90*C!?w9q~kzQWa?PfNf{T z)mZL57Ud(-lZifnYO^<&>ghat$k_qX$F&iS9+!Zt<7o*68**xU<ISX5f%E+Cjwf5^}UU>V<=_M<&5MdP{YBH81PwFT1UonNzyDs(s3;q+T-S=)Lk&RFV}z-0#Q7vZp|$w>0PEighJW_V0+u|z;o0?Rfu{_aM}BmNTmMS z1>ms`ph%tdVDrA(4?P08+4L8WByxOLoq6<<7yJ;Wt?{2sdtTCZr}eYSCNoJ@DYU#3 zj15gqB$#W+$Q20|qtT$Od@Otnb^U0W5#z4vx{Nn<1uWM$?J3sQ{Y+{tnh8K|_+**C zNGi}ORUF~d32nwgAn8~xpfv{hFpHRVYne|>ON$N-vDK(fQ=@VV%Fx}Y z`fB4s02_JYe8|hq>+=<|5l(WO+6L6Z!AU;Hkq5XG?}x};x*0-965=x zywtq40$kf<VNHTfs?jVSudFwqNcB!mb8fawmDp=- zU}WR_CDas)q|_|t22ls^D0i|iAt3>Llj|=tFams&rdRW^DFh1#`ymB9cOT}O2@ICd zML;uykheo5@u1ZFs_bIVPzsyF7|mYW8gEE~STWgsFH%tszgKXJ6EsP{4{6cHa=(;W z^QV7PWE;=9VWB1{Y*}kECJ703v7&Dp2CVV$1LFa|1>_NJlQRKS)P&PK0xkg`p*lK{ zkt#SQzt1{W#nn`)7)p&xd96wN&`Apnc6o}Szf7o|+$O?^){z#;%eM1370RNn6zfG@R2u(8 zCra&T0Utl8Ol=f&fQi5C7%&rup>|En1l4J@faivs9BeqA@_xOSvcE;FeALGex>&^( zPvNNrOF>JE12M^qux8F}gc-54{8iiKSGm$aXF!I(d6WFz7qjBNS~+IAFPKbc*z3Ox z4X4y67Q1La!gGbYSA@#ZEG&ikA~6R7bq`0mnpoCY@MtXFZI*EZ3L?Hgf7GaIbMmaA zbT`%JqU>j!r0jtKw5~ZA&9C*Ao1{pVriiGfq=*YdqPB3#$dRs_Ccgndcu=7r#~O5+sUrz*_+rV1omNm%;rC@DK{D7MJh(FzcV~6%_!Su#l zq}36;r-A1mKY1-sZehki?+m+raKH{08EJH^7z02B-@$p56MX(D=MQEu=B|Xa5N?Dz z3muNmeA-65E!yZU;8TRthwxip7y;isJ-Eh4zi)~=`|MAR$_f%M@OAHaWE@z=WJd>~ zKW<<9UNMOZjQlHpE%Wstd|Gw>AueNQ;5G*x_eLFkmOsb0#kI8p#sMVk4gQKRzyH{G zP{I>(8l!-@?u8x)Myv|o3lxE@qlgZ>GS7lq;)%q#z0Fb6idi~<*9hZtQU4?2!qsp9 z?v~OF%NhEusQ9+V+E;K8nE5vYljVJpIuA;v?tk~0Umw4Ss<*dFfpLP*k zRVWUW=|OTwWZHKH%Bp^EE%n8{6v&To3#bCUx7IJ27XLfVT7FZ*Ag??X9|7AS;51op zHU%%;kE3(=MKbf?(_PwfD9=JY&-t3*fS!x)z03gxcwGkcp=SqoQs)gcy?l?98%dv` zy;SXBU&mOua4mg!XcpE%HRMWyCDf5PY#7tHv>1-EGQW=M@7lDGuOG}BtTe<8^iup) zR^;-SteTV_A?34ZVQ)#k+jHbtd!(Z~5x%8!Mfi_};Clr;_n2W%YPJL5$-EGye2RiX zzBwW6Us6BIMQ}ZmctQuC?7f#NdSTwM2xFDxg)N!MNAnZWg|lMly%^P?Vxpk<6Dd-H z?|jKLPg`}OYXoe+p?F{}ht;4JSr1UpX|Xm|BDOi!t=x0==fE zP9mi~<@i$xH@!yj`!X)Ru8xJ#wb@JRjukGKe1)U}(NRp{X#U3V;vDu#kWGK=jBF0% zE>rPcnDx%#NrsatclY8t`DL3HhMj@%71tAUF2f$QPA!&IgqBGWK0vJ#&$lQBR;9Ay za}ROkw*A>Ibg4L2TP|wzh~sQxcNjydF%tKR-sn2sPB9G!3Q67H^_ugErsxWK!WMs4r>4pLz8#1Y{eKtX{!awZe?K%d`I`XxzdlF)KRqe@`%|)i-QT{@)Uv}KM)f(W zQJ=0UAy>R5@iZb{fV7lqCN88mG-6)GRn($$Tk^^m0s*3Kx5Z|!!+)JFpu5B;&l^>! zTCKZ9cl{FdmFQ+_U`rS)-UqRWoc6Ps$YL^^w3)PVk#MTw*~Fk`0g62FLZ#WCNju}{M)llo5NIEfnYbSJuVuMx z!}`&7{Xq)o*$0>5e+}Gyl2KhNtwpZ~l0OC}C6oQuXZMR^DhxTVY3^h)#-x0XHc5Lr}@lP(!X%X!*^`Sg0bU*8s38frvn;J9 z8s0-TUv<|IY@Rx#!hUid$daX_2#zw(>w?~A-^OQP@vLcbdYK_7E?Qx zuCyyl8Ib3V1$rNz#YolC;gyNgpI>o6D6g|h2NJm=K>+xPMk@`Ma2nna0P)APtQxL8 z*?PBmBv!e)aEr6Qx3sqM$+)K5y|A+U@-x}SW>b3#(5AWB z$IIKu#@pxtuf1-e^+N+p)9?(NOY6zj&Zn!cfhN5i_m6!GF2qs|BAp(EGB?)u@l+PV z6d4IXEWF?@7GmXVPtbRnmbn#|<=C_Wt1GNnfZjOv1C}2%MzX zAo{*UUdT6Gzh<^A-dU5SO{pp!xY9T~H3whOiE9#LqJfmCLbNiW3j2O(AiK1`ee4(} z8?A>cAVQ7GgtJ$$?23u_f_i0qK@%GRASI3<=l2iB!`-pPct6;3kS?|;L@Uiq(Xw$` zX=BZ*lLGoOck8^HS-j|SF2Mm`8~`u5)M3u`=2T6cFe^x3`a>a(%mF9ZBQzX^WbQ{rb9?{lX=y0&R?Gn~D`mS!<+YyHb&YdJDKRHfH<$ zdz(o7O8aS9k0>yx&_xc!EUK{6s#Idh^_)x30`Gbl$S&>zD}7h&jl0;%<%IIGxWwm+ z%ne~44zBU(MX0~T3MnO0UcVm43F=nEQFA$IJ0TY!^~jEHy_M_4a|vXBV$=%bRq-~; zSSp^^%va3jcss@kn%MDQj6bQ#yW^wNXFLZH!g2EKOG*o(O9{@Sy5&3G9P9I|(EcoQRjY(OG4QINm-)=RJNg02z_kst`av?IV}G6X zT1ztKhL?obCT+%c_9!qzyDcBjkWevEF24BXjEa3M{RZVU&o#P&JKDCc&J#-RErCyf z;1*B_5{J}Rn0@tU^Wn{mkwP--x`&HaQHQJ^v@CW95?f{l>Ll_FO|T*|zx$@rq^YE|nH`qXlCteOFEP&UBvka&%3l=qm9LWeSUv zbGv!U(%c-w*;K5c<4hh%Fv2`)+bPo~=xuA3_Dnj~WT!qXP4pk%x7>BEPYKIQM%+sq zL~qQc{WmfnPPZd!)%w|Qyt)IEw2x)VQarc%vx8xgGo2<0yN6biC!RZ#9jBK2%4nzi z!3h-1X?u~xtNPk>J)Y&(-oYIu7T+eVo#Wj@7f?juIgej*Xp~*t`ARG^<*CL}IYvq{^|Xv5lxg}T z2*s5OQ}=hBbD1l*55f-HrqfxD#sw4wXN`r*tfbT*(!;JPggpdJ^P^h7y~wQi>ixXJ zH91@pqiWwk5;Tf;PW-y*KGX#oa5O%^{-GeQ^)3Q}0|3mD|1*63omp)EWBB_29bf(( z9LM)JA<^bv%5lbK)`m1j){gdWwl-$gjt(@YMtYWxrhi@;{^JF$xr2@M|8DO2`e)wx z_UHNQywbX{-WYBA?v~*{%~vH`sehHpC&q8d;8?rd?vSb%L){`|4JBZ2bQOqGkFPJ7 zf{{fgf2$*Z1MmtO(r>|2cg*2;EATK5Mh@}$6Ofs(deGQBh%ueX?l66miDB>kevBk` zzD7P=eDX*tZ*#3t>QnrrMQ8iQCYpc5_2^H0EyHl1K%r@W8nn&R#sG^J7bUgwz|i)3 zn}IHJM{s|4F#z^5nJKdOtcr2A0iU+wQn2eB}+4i3n7VT2P>7R z^$8&NdFxm&pgU?ihs_0KaJcC@J0(k@$Ee9^Xx?8(2VlnoBXrrHUuOw)cs;J!OB_+N zp6Sz*2;je;K1B}2l`TX1Fvzh!`t~D0i5FF_I$F$tHLW<@h77oY>^nxNBt8D zQi3uS8!QI5I~I2B$ZM>xIfn33R2zRN&I|k@yX*~~SSEj#He< ze&x~2Ed0mFNZcXqkBmqe$XV$1x5TEeGk(@ztg%n0Ybuw9Lk@|OQ>(Big^x#K#h*u$ zkb3TUa5Mb69)+=}`~(*SRsh{KQrX(0>9=!;iZeSdg-enIZL}FPIi3%fr+IFVLqB7_ zPu$jFKfEQZjHCC_6DXwfL5x{XhnNyq6-d#p>i)Pa-Mlk1l*s~!N#SV`Wn}{of^sTt z$i#hNjYo-5f!|1ID8R&NofFRDN$n8bUZ7tG2bfOCa8p&xS~h8$Ghh%tus||57t3dU z!euT)_nQWL-guPn(EfD1msn=zDe51|)MM~);|8Oe6klGcNLDh?$_$#DS8;X26^>>n zLHB$;F8x`#u`iK1YiupAvw2L9mPlfCj{=OjPB!;U=!z0}0$5{=yt+V7`TQLG4xJQ# zl({x@^vDfRWU# zLkl=0%SEf{qhXGUJ@|x;EjxD@Fn5{|+>W*&L=dY}z=~WXhI0^6LG-g$M%=|g6=kMQ zYY>4fli#yum9ekGJ)P?^Wo_Lqe0l;M-8Bvu_*_)Yl+XaA1Y}zl#}9{i3OB1bj3SoCQ4Nh zM68vUDQ4-KCI#_5$miNI$XcoaQzO*QQxfXVao{=jB33BYiKG1Ww^bUw*~@xte$>SQ ze}P=1S8uxOc|M!`q0D6Q2ga}EMyK#& z*Wl+klw>+s0r|QHnK^&LfHgBB22z*CWtD?ds&@>kgi3CU^U8N&^91;p;MW#@#|8Q?yGRWVN*h=Y5-Z}!i5mIl&V%&js?_b zG&D1@5d=`K*b*@h82)aZOSzbpvS*6KN6MIje|mJ6ipTHImNc9m4KCs|Ej?QobvZ(C zrdgV^(vXYeMqg9y8_4sEjH`@6wyIR;U`+(;Tk5Jz*I8})TT8( zBlDV^uxQFiayeWuP}*uH&+?)l6XRuGw9*z%`AP(p(GqhXWc_0ur+sk!b?d4e^aO^P zfq+muBLEwqY#oe1gVLH47}3hFWGml+HV*k(Zro_*PfWd|IRQV)c)q0PD9Vm0s;a-dZDbX6$r4T<#Jh^&8 zSrWPqwbJ=!xXnU=);u_oJI_0Nf-A-Md?-7elbs%Z(uLS|vbR&j9HdzY*tz z5>i!V+g5cSIi=^@mdg_&XN&5%(Ke?v$K)j3WU)-~@EXx*2PJc-h>>q~sKnpxzDAJA z4di7rr8w4enthf@NnDQ2&uW`=1>;Q=s_bRXbl_)KO^A?Xe4S!cx@IYm3_|$ zmwnFZdbz(V_*6H`+qFvQ45~0vASBEY9?e5sR+tls&21=2BtRf#@fN9QR->)?J&7Fm|6l_uIL{&P5#)PmRs59vX)C3S2? z-NFDhV_6@q95h85N`HYr5GEr@!R$93CzX z@&domqTN!}6u^gCU}Yq@YCLvtqC66&{z*S_5uqPQO$dD8m)>D(vxTB_-p|5M98?m0 zquS5$+&c`pkR*WT50m`IrsK~L@=P%rR&ux84sr?_cyQ)4(tEE3VzE!V8pTacv%Asb zs5vUzQHN60Y@JmUCKl~Y6fGd-MRZOg2|JVx;a$CG9_HbD^fCb!-!uzIU*HHVYJ`su4i`IGaTt?wzhWJAy3%GBSztXcOT z1X`ulD(#;0y+vTLj=eo5)MC3U4QCr1)H8-n>Rg+q_qIaaKhSzKC$(nA_&*~kwz$1a z*$r&XKpw5g)BRbN=5Rz7=D<6Bd_$Tm)&vG*`^J<8(6Q=^^Ye<=lSw(7xmW{Bd`z>q z-)Mut`w79JRy@D?*?jEGHt;*U9r{BCVD4H-?cz1b^aYp}BZh#wZTVDJmsty=zz{~*9 zpHGj{GaL5)QXA=iwF!7|v48(n%^lOv9vy!ayqJ+IknM`r!l_0I1F!eW<`vF&u|Oj< zB2dDQ4rDlJHlB3_?tH}ol-cR=gDdIF=V#D+?up^~P#W?r1$Wbttls>U^td(uTd~bn z%8+?{K)&n&(qI!J{(zXrNKIYWYITTh_H~4RBdakyl;|rvV92p{PMw4FJOy+3RuElW z)#e&>z%`Pj#ua5>kg{q7`46fJ4K1fRv*xYor{~O}Y?#lY?bzlzH|~-#DL(`HR@q%y zp2KPagf1o0*fG25QTN-%?xLNVxS3zP;LaC}7ueB5&B>KLFVA zu%rr!Q~}~|@9vKv3PVmt3;GU?_U@h_zCU2)kjkz6ic@bZX6Jo)eePc{qV=u~I;}&0 zO`p&oJ?D6j<-vr(KG$D(D5gC}d&u;>O?gq^Gy;Q+bUjgF9G)=cPp6%*@$iTsL}qof z2~$;VM5XviJspIU%wpoI{IN6&JihUCx$fS$n2F`)^K=<=V zl4{z$&CZM6As`KLhB`eHLlQR7gD246T7HFbzlO<6@d*hkCO)T%E!YC7P5QSRsFwI_ z%sj670A@Y;U=66_U;g4k` zU8Jb#n!k$Cara8<)T>hE8pas~)u9VORPLfGC65s;H%2K|UiR(d{H{#ldQYV1YhaFT zTGzXuzbc}2rn7R$xw*rAZZmf%lTQ^G46#`aX#siiOvXuARb^5krrI*_Ii0uGq0BfZ zrP=5f!6j@6&>du5-4Og(0u6Xz1e^z3S+uWj;r(@6aqoe7cv3+YgUjvd4Df~K+D8$| z;;_=LT;+&STC3Y$~nZHC!&cjkbG9$)f4!!nb@;CoK21 zh}i~a5dpE|=X;@e2fmxa6JzVhqpeU!@2SRLSMgjU8=c%!C+!3HP3$7hkArU}YXX8-kVdcO= zqkB}hyv#2CoG?#S7uwF3W6zo|-QO&k>t`R$J#6G8u;N`{ja}Tb>$Qj7sJj>Lm1YvV zRAiSK__0bC0Dhd@`i&Og$R+KAWwd~P7r{Kp;F~B2LJ&X{JAHpz=gQZCkw!)U1N_4R zsNPF$YwOF4shy=dB_qG#p|Ju7Gsyi}73hB#Yu6h;(RI}`W{^#AD1f*;=nY@09Q(&j zJ!Ix#;gUJ&SyPW1UJ4h7$D3$ld+ge&j)Il%CF74F607+WOT-#N#8dOflZe&>i!DzPj-9*4 z8>>VX1d(VTK-LV7DXH(lY)`yN@ASP%%Z7%fq`P#)njL_4I2*^|=!sEji39SbyNrW) zgV&?@Vb8O2_E{+!<3W9{8X=tin6w1pV@wAq8+3K1LJ)&*gwSnY-L@opNEfwZY_lfH z4Mi5g4{LM^U+6`7ieu`$qJ22~6`~SIUIkGg?rBdFi@6OMi%2c}qoNw30+=Q%x2OZB z(NP8MYJFQYA!A=N?CUysn7wbAY=6_k15j!97-F4^KZDHl0oW=#cdCQE(T#J=prxdM z#(D=Db76g%`*_&^_1^%2T)!B>_wv1nHu# z3h>f4BOgrWRcQ{na!ps=`zPN}e^^D0m75JT@enRbVgRYKdH;TyBbop4feG|oz?IL4wg8r`u2-b}Aj zS<9@grgK<)atDZDDR`6+aq^?GkH%-?8~a9~f3FY*mycE-S14YfBG5cZEd}Ha`;JNa zd+I{bKr^gIQ$xZOMn`;ffnACZH647 zOwF;HYE!3kp*T*pD0G@=^<<#ALD6#XIYAGHDx zyR8itMOOQ6q104^BaKQoI!T*vpR!I}x->VekZZ`TVUN}ErOqLy3#}QIcB7gVCsG@S zq1|sufs*pWSbq^F4L+bDNXwDaZj86TS_Xz|rk&)2Yt!o_Y8~2-wkNHX#F1$n$Yz@3 z$pC^AoESzFuG`ZVF01aPCwgd&?nt18C0!p?-Ic8kRluU(YsIfoj6~flT1Cb;iaTqL zWddI3DX7;B+Pkh{kaY=;N=;Ii3)91TO3U5fROl%4cD)~*k1WmHeAT{zd464-@7&&m zxcJ2F-qYQDb-taPgPA=YbnwQdA0Eh5`0(pNsFIEJ6@<_gI_@~={5ZKoa61&2zO+tu z)*&2Bsw<@M5+x`~gyXYE1KdC%iiyWLQ&@g00W$)bibFfnbSN`eK2Gz^W_e&1VHk+c z7m%+M0kL)%F#{UHeS}MM*3?!ngix=!on(^1 z-F=fi@j^?d>mcPE7@*$6TQ>s5sB*n0>kN|B9hb+hHk_}Gme_rw9=ciQD3z>9Wvh^ zEH4nX(wS6m_I`Wb%&PH|RpU2xh70x2OBL2@W#_eu%~pjrvz+=L6DkopLg6`8dlilz zL`Pakds|cdHCp!@S_JM&r)|}HygwXBc9jV15m!kdF4r-fw~8k%N(vosa5{MW2PJe@ z{?rsJ$FuV@kdYq)4`t@2A|X5Y>r2Z{LWH+v2r{gkMP+ZzPO!vJu*gj`)skusu|NtNo*Ds;Gp$WS(5(#{JS`~J*iiebi!-lEGp!0Ut_t!zKHiA2}cC?$=1qJx{JbajB)!{VHtqXcT+=+up!LQj+yB z^AZqtlQ*$v{%Ps#I)4lc-+5C*x>Ka72|o=?+LY-1ewE}-xD8-f%L{__PG_NYG89DN zH|!dK%L_f0are^RiL5#(Is9BkLTIdm6Vs4&5!Gr9FH~;Mm%d1D+FllUaLI4)=l`Zz z6oEZoiHj0tFF?+FH7#o<-4KeyS`VL>{DBPA%+E{_d2RT1*MmTES@&dofTHQxdY1D-;Nt`B#%X;SJvWw z#@eVtnMB(wsmf(A{IH|6C^sWZ&fc{MMiVSFup=F*|o$O+UmMFF{xbB=!Z3d*2 z+!#kKu`ZZG(u8CzhC|*^cqP`Lj(^UWDRISYE{`@{XUex;-<`x|*fsoYUmTbR~GM6=J4 zEcM#_+0L400q0YKaA!ki`-}Il*_niiQIG`&001`t;6J(V|2`*j|L>Ze{U48v{vA`a zzuUV0+D%}jXJn;kVqnx^U}s`tVyFABj}!Im4NT1(jSL)}?EjyAK^iMPYdsSq`~MH_ z{ws_PYb24!EuA_>I+}1hPXe?a#cBgUO5)g5FvVHZdQRu&N|%&0Erp8k!6Gyz#iK5` zq&F}G=GbOFAH7cz?mtc_50?>Ef-VZKK*Q-Yhn}f5sC0{~gYi$YNEWo#Zj%L zqAt*_M>iSGV29}TzM&GP_Ks$eA*kTc9IJuN%zdaqn0>GC;Ej!e)YxsQ4El|YxKCnb zj(h&j6J(B>klv8d{yPB)yQ%@-+aNanyn81byKJtUZj5flQrXhoP|>6@WHSC}x9>3t zWa_uSHj*-}MHjpXPn-HGS1G-e<{Rr1>o@1ev$Cpa+m~o-ZVh7bNOFH$pPV;ow=8sY zZ6w_S4qXE>!q_1wwk~z|%Mi=DTq3XmdlVZGRpXDWUo^RRAWGi>K%YRZM+LLhR}%EI zdWe#bfG9D&RT-juXk#7(k<$D8>GPBZenh{;A^&1=~jiW8FSFt!mmWRPl$B2NoWTjHG z+AEW63R`?ZpXEGB-AjuE^@08g-q=7xN3-$Rz1!4()!$xASxthUTqgUiJpNC|FaLS{ zx_Wd+WnK73C=3wc=5+>;Ts|s`h86)H2~dKYta`2_A4MH1TKzD$`wFbLU!xmtC#*Dc zHeMgqXle<25pelr#xC(Rno_R?=x^H{dt5@}zBX1~$Rs&l30mGCypgJSspxP6aK<&n zurdbKlF;7hul07Wm;`daVDABg{3h7sLRWL#%HX2&K6sOR_#?Yvw(ojKc@Gu6PW|C` zIwigUuK?49T%Xx(5EDxJauP&re-pk4$a3tZ-9mnO&B+2c*c~ zqkjf2u={h05a=r#%7Q#{pswhgyoofcu1OpmQ+*Q$1Gleo@=3aA!oGiGTfQ9ZbptVh zH^U%l3ZsJo0`M)+QVryF>hCc)z5>@Q2zqQ`U0rQA!LDz$ZEqoMvgP`-A4iGiYcktPhmL-xxV1-cI6a~O9xtLqmbhIx% z6jjH@jK$6#op7M+!ozIvLr$DgDMsOk2#Y)f@Q^AA302Vi)VU0oc|1b%_6{%uNNxY| zIyR@_2&Wx(a3Og24`lIFgQ!ryep5-{DEuQr&1hz%Qi??|p2=5VPNe$rS{m3b_Pq+| zy?*-R?`tWwW%|2b=Twt(g=u^p#I0{S@`iW_JcK4wA8H{PiXr;ry`>$vnrapT>&Qjcq!B=86eyhzu;$Ou7zJnpD2G zm+~>%=j16R&}M54Cy{6Se$3-72_Vp<70Uh$`6+o{p~NL$Lg^&FzYp1>`>CFvM!had z>{8dekCb6ULZRAPo!$_d{_JEkE>C}cyXC-qJQ!uZt()1BzsQIsa@1X5x{ z;t?&{7&N?JT2Mlbd|iy#a=U~cKsqWWidTu%lL13x3${&GVUf|) zRE)cJ1^BIqt=zWYL&H2#+9OSX#19OE84*2@T-Oyh26)=3iq@)VbcPqz^( z;Z4aS30Dr5P?06xGR!s_u~%nWS1i2a+6>%dwCrIta;)+zk-KYwrdQcZZpaqg^Q;j@ zte8wM5mo(rTn#%S9v`aD8M4ENmU%bg$?haUE%NdiH_nX3l+!i-4(jd+VHR?mG90Pd zyLiT5(_25nS~5Q>y$1{hF3-RMlPJ@#RuAd^;<~w7^=Y6#o~R;WB{BC6{A0UF*dE(ff+V>cDV`H0U zmyy^~F*-rQU3R7uR+DM=ojaDpRL;WrjIvp>Xff!D{kLQjN3$Xc>iJ^pGDZH$-&#@o z$$Ik~<=aM!MoRkgWJ^Zt1JM>f0xU6m+m1=-qApRmP4ITuz{pXI%142$O`YW;X(Q#) zd$J3)8cmL%BdD%EE*vSU(tGQz0rDDscef< zDWva(7XJOZ0YY0Gi28Ph2$e2={5VCHdSe8Ua$V8QnmNhhf3hGrd7R#hcAs~RUJP8} zufa_EC?L0iL;A3guls6J`u=!tymJC)Ufwo#={Mn?=YkXMIi0a;%}ujqCg&Fre;JkO zwndLiSWHNHmdIuAPULb(i%r!mt6;V$layT{mIT0PWdaV}Fk9cEh%H)HfUWRx4K&mL zjJR3fG`F-AYnNExrPZm;N<)w+UK<+Jk13mY2JHbM>tjf*pNaCzdAJ3mf5Ha233%8= zM~&|7@7iVg_+)~g?nm2m0hh)$=Iw-mlYQY@ckidLeL*>~$F&1E_CJdCAuURm&lv>B z@}J{aBAFx524k9XX1lroo7efgj)rLwq28K>07fPQ1QZSUFTq>EERRID)!FfOWL(b^@iU_Zt3snC`F40+oQXv8;ON-h z!KtmS-4SkQ)wFU)Qk1E+t-Z<4#_MYNe7RV*xRJ_Vf1v=D%1$eLyb2n%^{)ELBllUb zQ=BWu0!C%aN%CAs8xT>|Ow}s5Ba=EU_s|tbDk5pil&O-VJ7p^sFHGK4j~TL_l5hxA zNKw2bzj~%gS-5I99}`lK)lVA zZigAUAgwCKQ#88Pg~TK)csTp;* z1NRS3#w5fL|b^aW^|N07_k{-d*G^SY_v*nS?tZN?SP#fe}v%2^YSj)Cf5f{-So2*ZYP9~ClDbTem zXn6=MIuz`4R3)7Rq|B0Q{DXzBiUj2Gu7a0}<}sDy{XpHj zd6ctmema}Xf-OoSxO_pA3G|Y9*P_Cl5*$kWk?(4oAlSg!C+6f^C6VN&yS%Nu`z8dn zXvZhRYG*$L;4}&)NIY7HMSw+4=|SO%XcC}?XGeahe#GXu70dfwfR+X>ORte*gW_|r8{$c1G+z$kR2EfDC3m^xEZF32A zYd6>@b{kF9@UWW&z+{4*W*az=f;4%r?b}8~n=HUJec)t^`9aVkqS=3=7iPd^myE}b zf~Q>)B3)FcHkU-W-ik1NM)E4B($bg(3?25tU9IuU&BuHW z2e>}Hv;2FIg)x$AK^L)!0Tr8PpEqYWu41CZ(tNGPH<(5@qx?Hcs)-8lhse}I{NgFa z6{R>TdA3$?W4YSLz%aGv|kq?lM=t*1>5i6YYesj{U zW1I*c)I18mJVx=y9Z(m(*IYEEOBY)tp%N%0sYS&@=5YjlkHTi9>r_t7nAh##-XV04 zg5$9deTQnuOFn)9J|}Gge!mIk+qh!-l9=Y3K;i(iy8{oUyF?;SkTB&ig3!<5m0{jt z1Dc3{t^G)(>zw_W!{=Q0%vGY54KDs2kj4Es$TIntLe@W&L`NfsKelswCu>JDE2IB}v!4I()nA75zs@T)2?r#R zKVe%cmSGh}+yEq}@$!~n@_<+x$9y2>TBrrAmRS~ zz_wrg*Sz90lih`0qKq-v`god0XWQOVGS4elQ0WFwc2@Rvtn_7a4iGMGQErPYBZaKP z$Z!x9isqOt+{H-D^fdEx=Phh{ozXP+wcTQ*qk6w(1YOwE8_!o4p^c@%mue48`Q{)_ zocPfZ&zFn-m>xI=87cTPTeAa5(JnZS16SHi+JRZr$@NR&xF&wRfoC8?2*g=q-6pO4 zEQ8u-tLG0DP_=L588U!^2E`-S!;vZ%$`i5W0R_aNL4Xp0J^%6 zZPCy|8qp;b7v1sd=?eSZ;{MJpgu{3l8EZB=(>uI%tz?%U+Ac)~Z+Dr_D%20ux3uvm zkc*0AKp-@djHHEjjA#OrNb(h^AGqdQ<(7@@_YT;MJvT?H(;43b?+cy3&Zok+k}Y(k zNbf<agJ}bPw%2jpToD*t;4Ox?IJG%N6c+M2h?=5_~GeVtaTGq@yR( zxr{z}e!v#Oe)|>pdW?$_t>lQ8t@OwuJq&a<6e7GYb44Cx$T<>}3;_sYcNFRQR`=c2 zv{U2U){XW~8)Xy3FDNVPtT4$(?FccL#f`S6mbxI;>aF#!JhCDcSR>G9 z&HdYO_%Bfg2R8U^`VEJ^*rrqDj%<3Mc>7D$L6|LI#8j(!0ucj#}#*;p*;$~|Lao9#PB8-V#1V$<(jaJ(p`-};awNAeQ1`+W=(KMj)W4*@j*(T}J zBtWPmZ8y^4fr7@8&@tu8g*yGsXm8{zpSfMrdO1`4iqu;1k)RsnJ~p!;;`H_jn%XSR zndC^|!mhpKDwY}1C?CL|O2&f|o!UtGBFSb+teQttJ%`;I5UXR)=vil*a2#zwI=Zz@ zWji+Gjfo6^@IhREdxB6Q+BcgH7ydDhSJRSS%-A#5^B6$UhkM&BtHAYwWCFw`B&rM3 zw@|>7>&8Wv5|88qOe-h(qib7JN6s8k9d);;$1xN+&FKNhg_*%a*4l#8P;20!R8!JL zt1&!8^%p*%FqUi48Vl?vFI5kD35@YwD{fn_rXbl{s!Mkz$tvQxJ!<2kIM$aL1pH22 z7u~8Z!juy3C6;UZiJsa{ zK`HF^+ORP5NOZ2F3`=~c&VUiQEF$20;%XaRy z;Z-I(N;Jr@9=hT+jk3p{Bh#NtctPFXoxhX=?gjw6@J@njCX_A?LF~1BGYRO+m{GLo zS#cLWAbmerRPh?~mm;%ob(VCvEf~VqZHcyEsgg3Zr$P~%(Jwm)je5SSS(@Z4Wbuwo z2XNhEwXqG#O>^p1RciIuDM3j1DAh?}Q_^d}qtl-@3`tu|Nzw~N4UT=pIA>~*qrzK1 zk1ShbLIQ5@m2s*qrrwtA#~H<@gqemD7Dq#9$NZRwLumB$@8!bHxFqWg1X;v4c(C z_}gKQsOTJ+tGYkk7H2{jRa_eEoR94C5_F2|@wu}4+~q#S;<;PMlVQz31XlH;+toT- znRhi_kjH~B_YpcQducIhph7P0=iHO}I7}*Gb<}awW3c+z(Z6%}Y8>djvk`=JHJ8Kk z&9hpFML&V8a9@;;coXx}6I;Zh=(RerB2pbzVC_|9zhOG{?irk)5cZPNg{{QD{t+So zUp}wl|0fBH;(tlP`unx{-xk>UU%o;A9We3t38mG)9wz>yO}77iGQt0{$M#S8ov{&# zNtP@8P884^QUUqSNSq=0Ea2`g#C6(s|5tz~IV3VSst{go4Lq`tkG{deJK zo#n|qKC7-Mw!JYMw)X>!SIpoZ`^8Mly8*2~4>%2)-C&UNCq=ESj2(F`P?mH~DR~^v zECZaLV5bRW;k_z2T^CU5f~qjDf6brE+buGI@17mJe?K*M5UhxcC^Z*CCSZO%!VQ`L zjSuCNxcI?p#so641hLu=w%L@m4~tAs^poPiAJe4_52TfnU8F@eD<6R}j2~414%HGh ze}EC;$6=^y19FcU4-j@vo<9P`;=b%;qQ9=7w9${O=`N2$u^;wxf7}e79iAeZ^rEPd zbeECbI%L$Bo#*iLPR<=f^IN<;Y=ttv+qsz{ap!(L9vu__xw|^PJ$Bf{;NfLux3VLR z?Nc22X+=hJuXz{>XU@h9Vh>C*#{jcfXQ=(D`;w8#(yWIFCaQZ20pdgsW*QH42b`bO z`fBs+@$`6lxSzV;T9TRQxqY~q@VR?_TCxES+0prI|L}NCr{2;0)HhC#u}S&PwY8cl zz#A+WP}pzV!-eRDOAGY1FP24yEbAS1%g_ z0aEsmd86osWF&Pr0M3 zDl6QZ+QM~eu^1In4JE>U&Zq;8hC>|DL9H5W)!IyG%#D8n zruo-$%FEJPd>GUq@qj(_XB|dH0!cbz!5LvJDtbrKOHPx&0kvO$CK$f#1n`A23Na3^ znaF5)`crz}5QnreKyg~8FAZ$Q;d<0XxPr`6zp=~8Fg@Ba&q{CIk^2`j0-DqOJci-? zmArd!wWLwLewJQtqkeO2$*N63!k?;QqulGapDV?W$c2hKfz{ z`6Snn+8;XgK}F1FF_(^Y=O#K#?LxTJ780WEGI-(^ZPXRsD=Lqr5xU1rssh1Pid zX{^x+<4U(rB|0a?F28Oocr%~d++%rkNz0xBmr3xI#(aU>@4cd_d=i>5VnSxb+&pA|CMAc*Vc<-BfBC-Og=T4AB>E7zk zu4b1m3S(T{89n*~u}lc%dtTTY1ZN^w)26MALcQ+u_IIN#fqyuud;`)Rt!)n)Wj*MT7j?@dp`SQAciQQY+o;*Kqg0cHl}(isv0 z#0%VCk|9Z|E(qbbzW&%C2S1GeO>GL?URi)b@X!rYQ5Tf)PLB^ z5w9gz#E-Yj0_oO9Afe>~+7?AgE7d2ah_h3uTpLg(Eq($C-3?nz$bbEKjj1*PK%~R= z#Ya1=R&KycCN`#DSXg*)e1@L=JjLNZWhWm_zWH4Z)wS0vydg5q>dl6Y&%25n2#aZn zM?7Y`!Oq9;3)V$rFM%CR2&R$E+k4n-ku$;;UXust?Rw?qX$Vtr+f$b?xE$vR^XiZF zD#8XoYfH`-7I5%_NwGS@Z%@-_hp2<~Cct$IWI4o!0aHbEgh@czjT-X-tdVaiMWy*5 z9N-7i_~IuN+LSpP)FIrAM?9-(88kZzFY;QHW#E`9hZCg>j6m>blfCa|kay5*kAPV) z{2q4xLMPhRQ4(_42dgLh!`hSa%kEwhy$7DO2bUMmhu52(2VsA-4YVMG)pZIYfEW^N z1^l2g(vEY$K<@)c(TC^N{66Ux0eMTbVoQ_?Ji$cv-tpe>1CzszL^Au=JMRZ^(GT`9 za2Vf6ky|M55(6T`t=5Mxsfz?H^{C0o(dPU94Bj3Oi|2!lur$bnaPpur-70?#^C1D(6L>ueY{9NqNX%B6WU@41fEZ&y3KS zYSavuB-l6y-s$*xH0~y9Vt#|8jBX|D^aB3~X~~7}=Jt~)%qVfh%tO5WHgnF2-R5|u z@iZppV}EsOCjmIB*?VrWJ(4M0#)ZJcd!I!Qd5t58-j*X@hLp>L z3|UBU3RIjP8PMqT1E)LpI|r)Kq!sj$|BCkzXvVFT6WbeL9$t84fz-iW9u^!gmu;=< z{mywfAVv0LCX?HvPn-S=$_%yIhiVWaJRVYwq64z953auviG$2cq=r-{#;1^p{fl#t zl=(MN-l^dSw;toB3&)psD`U|*!TuwLboGyCy-Z%zH@J{r91Lrn-MP>{adCh!Uj`qT z#!uh7^A~CdH9>l!r{4S{U;ef>_wN)(GJC~%y7WCI%#+5PTHl|L8TU&7KuZEORzNNQ3i$1Hh1hU|`6Cr5+_Ubj@1;0k z83ibEw0kGB!P~H7a%`qx0;j3;ARd7l2rr+6`PV1zwBb^JrOcQG?Fn{k^Dj`u&mQZ@ ztPCGs_ym--z-NU*78%wm9+nnn%6}o;1#CnZkT!Z|$w*Q%%A9U`Ns#~w1ES0)YZoDk zfT|;e(-2stN?V$xl~_bZ?g!DMFj1-`=qMn5@gIT)-zPSTgNnZsdVbIz9Ze(W%M+*f zsk|X|EbJ5buZ3sXii-P))gWA2f*o+He@9U4;^M6nm_j4Bc1Q4Kp=e}|bl*<_IYP^7 zbRGm7di{>b`8>(eSdQBA=xDk2OpTKa7rbcT%<*wQD0Vt1n6deOZ1@#s+2!+aJ+*PO z)9H19wj7dkz5Pjk0rtgP3~3m;kB&4dlaC;cl8uL#KgcdhQH=bgnThWMf8u`p%ak|Y zzF+Rg1B5;&CNa}J_`4oJ$S5Hu)M2_T<&`MA$@wF(86sI+Ow6orDwTpna4M2plCjj9 zu!^)A_%I|Sq@x1O+wKR31O-I@DLl-Fj@)Z2I4}*XzI^)~&ygo>uNq)#P3?XONyCNg zuM@Wl*COjM)MSb(7d$*(aH16sfd1ojs|akWC&|8Z$t}hVCjqjc-p(t1JEUqFA@Ai` zFJ93!k(4!n-BPwBa$DH`()E#oewWfjY=zEiuiLw-jODE@54@xo2ozn07}F@FV}s-6 zSWw~JSyc${)JY|bH4F?uHpr!ZJ)=088YHX;^oe!lCU7vrIWzPBLEJe7*%EDQx@_CF zZQHhObC+GU%eHM}@3L*%wymyn`gX+a(}-x?xDPq!jI}anM6S$-vHmf}_n*G)OSKDh z9k+AjHHCARJjuy!VucoC6{l!NrEf48yOf7A`Z!|_VGJciy`E0$YdqWezBOts$@JRK z!!TOE5Ym!U=r$6AKglwSRBCgz{bdq&`s-QhIVa0z9CD(Ki`Gc3clxNG58HlwDcc7nQPmSOBtQ*8rzQ4g=es-zVO zy4OW~G_f@XocA#YE0W#D8xC1skzu--uUbpf6^)`OIL<}v3}4~tuA>t`i^c8K>W^8l z;0O`QMlLfyb}-`as6+_Uw>E-A-yIk+x|S#K{7Dw%EuU1{%ooG{=+h&d4K1vf_Uk!a z?(%66m$vt$@eJPQht>Iayo zUMcEJ24v3V%Y8}(oDC5Z=>$?D^=MWVqa9^*QecGMYe-rpQd)R}2W%I6EwByI`}s|b z71>F3U8(qvL>;!YTJ2o_cF>SbiDL>|C{_eC5Z{qn-nF`~Pbx|+E6l9jwq1F(6CF^Ex?pB@iCPe~ zr%GqyoowMsK0X0J=#82hiNMPlL=I-h_I5A{I7Fs=9B8ZK_zIY@WNg!M)oMjw%iWHL z7w|K;%L|LyUNqIb1;|RtvANh>CHosJ)?$pT;MjDvT{gN-MjHwu6QT_9T(py#yUsCu zXoO7_@7{6@`%u)qVt%-#JgnNZV3K#d0(6yv$Oh!=pk^pYh0QTuMKpdpA&P|FaeT*P zXAc~5H-sE(VF2x?8Ac00m8^t6&~m;SLLjtp0C0|&a9dp2u#p8WP*vA20OiJdU2w+6 zGv>H-UCVk2D=ux~nUMq{;%fRw+-mwWBsGTbNwh%&#rL{Oiuies>YIt|X}}I;*TN@F=3W4kxRK4uo1R7*FjP z(t`3?8_|lFXfleIM25;tYCF*A7;V&}*KH+PYjCV$>p*kU2P9~MOC3?=9h_iTN0fT% z={xssDKfIL3M=DktJ`Sz#)OgRBASN082r%MT6R}PRNf%e!i<)K<_ZL9K_$<3sl|(a zwl9hdm4JqOmh%4*k}%1iNU15?-HJc%t$=4FoN(tXs4ovCVoq0Uh$}-)jAYSO#h1c? zOUA&?DkDfd3j#%M`s2vceJ-#n^3O)*Nvp>2Mtrf~&1Z)k4?nm_8-`vi`x)T~8;#%y z(eZ^e#Dh#}0-C)M+F%&cH`~xwZ$QvBZ^hHp0@2l&P(_ee zB+NatXezU4hr!D?$PV6{46~xFH=0WRQ57BlgK*hSs-u1+U382ONUhhz$kKw-L~Do; zh73!P%PTrH4UUN`I^105c1WxM`+Ds3-#9apH=sB_7s?VTAL^oe5v*xBt*z{P>W2Pf zSkWLhg5T;sJZ1%XEqks`Ei!KlJJd3Wnv$+y+mm^@z{GA`JFyuTF!0zK1|0mIZ|t8k z0uIR_VkdO#xTDa*5NFmE@2O_;Ck{93L0c~XHwNhf^cu0N$ z_=vm|jaPB{;zvS+iA5rXt3Jxwb0^gB=U=WOAk5gOhE%p^gXSb47TexwmJ~UyB-)|V z2gp2?U;-JCx0xfpGGh1I=U;Ydl+Pz=9}Zz3bsY?CN(Bz&m-l0f>1o}^utG^Xl(Yqv zQQ?&l0+Kw9qSl8kx z>*u^uUcYDn2wH)AKu#=UI<VY3jvI@1B&H10Gb&cse^+ z^*M1G&O(L77EecxutLv6&SH-tLAlIXt}l!=vL22qNw21e%AZ7L4w9;ob=H)>y6u4Xpg>SBAOYfd>nA z^#Ai-w`a`6eZPrXDvfq175(bCRfJyzkCJGOD~-`JiE8m^B^t+~*ue#!V#@`2t?o5K z#vdhBHGV*I>=Xik388V#$Kb<;Z9|F9A1ve;smkS(PIxcdgXwUkKKZclPT)HNalv#I z(y^#F68I-&xjWo58-g3M!(b42yWEea#*sN$1E&hAHB~`5-{_i!)}YxAu+kQt!R@(J zF!`t8x8Z;jLM_yIB!*(`Z|xdX18nPc#Ym#4urus@Ju19q1`TIIcu`kGoOM}^t$Iif z8?WvMEDq|4jF$E0J1K5e!}s}6GA}Aj_DKmvCEU%Zn#!_+tmGxIxK6!2b;}-Ag~MpubsOdo^h^+Itk zum$|$vZAHO`)XBr7VU^zawW1-+i|4lTmYxc8TV1jOh7Ol-kgmobJzpHoglO}g=B@i zsY1A@om$IZdh_i%HB=@?&G2PrWZoTc8t^5?a^%&u+1=vj021%E1wDX}@sa;JN z=O40qE;D;UvUm=7lEmr$d8l!Db0=(iNf(W`cB~m}Mcejo*W>Kb9Mx4HBdum>Gq(sW zH`Dalgy*b7FR))LDk9xkW~0L22#%-QZDyd&BDc|j4kh{ z99uo5r}xoBV2+Q2r>4xq3SYVe{EPN)yN^RC?_&I7SCvFf1T1`c1E2T`kb9>jnwrv; zuKXRT!j*LE`66WNuZXV+q%l<9fBXveJ-YB=l^*A|+s5=KZnMk>d`~ct>0}aZ0Vk0t zp$8ZlHAKR*qz8nZ^rJP=D4Hm&%1f;CjHnvGF}73XNz&!(ysIKRK%-m?Jt`YrHo#T} zn(iz`X(e=(a=8p5=&ZPpriHcRE2=!gq77tgco|;(w()=T(!Y}*JeHBYARk_prnn}0 z2bFit(L`$cTA{8*Ld>@#7{9?hMD$vG`4gA)E;-t&xu`(uZ9d18u^^n1?^S%IrsPLo zDLr&e|G8?NLTj5_&D<=k(T#PL^9vIbTsOXOW`@E5zx|NN#xK7ocJ(cqid|?OL#Hbm zvww70C0q1fZ@j#}|HOtrdyVJjcRCio(tY{*7|F&4+Cccr(dBpP$)mpAt>om}<@czP zn>&4f@8QcgJ$?N8%Cr28uDJcjLxxuUcJ+@C-!Jdq0@>VAIE{I^i6_4>rqE}SrVkH% zJq$A(aAXh+NcECRYE`8kw*c#UAjOlUlT~2D`VZ1b4|wUJ{fwfGxRjfQgtSXtsh*Hz z=Z-A29wtoVX_~Pcj!cebVvYG%{!kbuug1;*Q$yiboxdg+CH-MFQ?bF8X;ej%NZ?$| zD3QFJMmG(283)-3>k>xFEZFfy-7FnlyJW~)WgnjtUp_(rH#kUKMH~MlogI-BQ`~B> zoPzh(QnULTXWSX#$&-1IWp|X{2U>Fx!Ztl$3ktuS@a3qgQZ-IC>KISneQ+`|8}GXg z!R3}x?_^0~BjKwVELaT()=Y-6KnDqPr<09y&vE1$*Cz(p)HqOV&Pb1* zJEcOjgZ_Cve$J7ZLfA&yCRvLZ?rPZmf4*s@^T`f%iMN=?r6F!*EcNN806;7_6U~zrwdZA zrm`yYqS&o)x5|#2K5G{GqvrrOZY;)lGMHjZCJHIuc6YNpILz^;(!-qTV8YjNHjaJ?+r~5&({}yRCQPQ7OP%@J=`Hqfu*B2x6g0)t z$;c%A*~ob^p*WF7zb8A+8EUeDQ#x4u&(UnPhl@4drY9STor6P=ar4Ez zM}3j2=L?~m7^EAtV@PC$Rj)MPr2Oytst`>N!6zsZApAO0d~M~(eMM$Q0tE3i9*Q4R zlQvHnp!*6M;u`Q9<4yetA!9_#Wbw@vk#ZR;9>2JrDq2zb!2^liImpwo^q}OHCreDV zAHcuG!?6@x;v#m*Z{GUVpteOwS}}c`Xqx+Q0?L` z9Esvw%yAchrlZ^_B~Uswjbxou)9 z)_qN6BF2DrJa;_Xx5_8<@u7h)fF<-Tir5?wg~CbvL7a`m)g>LAomSTU2on>=<6vO} zoFkddb9)_ak+}SF_-3QQC1J7N=t1pDB%GyWAh3w>pEn zu`@RYSi<;XZ=+XX2U7J=H0TAor;VG;cK=m|r9@X<@u--dSeevCr1t4)KZut}#hIsjaZ18+3rUZj=|T+} z70i$>t-F>&!swZ635)w%&4po0d|~twW+^)jn;R7nZ%RLgV`M_rw5r>I`ak3-^$S! z&-lVqRn=;V-zP<93VnKOLYO`0f|w98laf|0WG2uZi)16qD(G>#TtO=p&W|C=p^SSt z6gfGKQ9B`NkPgC+5mPbKnDk`b-Nvk)|A8c0oBozi1GG)z10STBV}6yM97&3RQDhav z_KNy`eJgYQnti_DsY(PU*o~ahwGQB`gXF_*}k4v zlamNGL@&r5{SCU96RSVdq8BYszI_3)-yN7!09tx5_aa^2Sjzwjl@=V11*S~Z%LlLXucP9f)Z?c0%k zyF-fd&1??u(eM6&K1ZYT&E|91A*41|17vv*$``994L7NVS_M2 zd4<-P5Ydu+`<2xGO4ZBE&_qtDn)&#(cf#fv>77mDqQjb}e~m199T?y_==1N{s5u?B zom4+$1!bvONO_$$M{uQpd;wAkuszd6x(&|7u}F$yv1vT3h^t$t4k9 z^N5sMrdKK1y`1n?b|~{?DDosIee;qSD;1vEme?O?P*(DEYZ-whs!t8!fo;|zJZt2$ zhC&N5S#ySS?f^?3Kh0lna}G~Res>K!8^uox#gpmdeaNYz$F$BEoq7!CeAO!vaYHs| zw4lv$jbY6bxGgkQu5msw!q{Og-Z||-Ep|?Uw2{WHlMAN6m7}0bH-A?%Lkx9GzO3S3 zDp`HA3B_^1Y2Y+odECJ@GG$JhX{u;#YUz^IWr=FX1MRbqF15(4)vfci)%iGL0&zg^ zJ+9zD*;AseH6e6nv~=-mGH7&CK>@gB+ZOo_)vRB%e=rX*zBr$E9#VVEuNp zjzYJDdu0Rm_KDdk%xU6%5n5J*v+hbyG1qRqB0b%m#~x-EA}o zOQ+ZteDMBI=bSUb`nlv(?Bh)~N#(z%-RZB9-#`s_0$U4FH;@^(QG4DvNl7 zXr-+Cb%TbHzIGd72bg6?c*ts)5hkO6Rda*5aMSHJ~sR_|v(G zy2wSbn<0!;gBIs7$yqR!Kv*HG(f4Q?rsXctcjO;D4w7Vp59P6%rJ%onI1wee;xRHr z=Pbw=I)@NhM~Gx7iz6iVet{9ZVKfraI_PlpA$M#{y3nEBa2k}~tPPn>_TFlvCiF+# zY@EzqYmMc^jc(gw-XF8{uWDO~GaGoD%>2M4pdFl!xAP86c`Drkm=NRPTrmSImu#2w zs!Wg^Gj%p;?cChY7V~dn+K|#V1S}>>T-UI{aLg2rkpbE;=-WmbbkuW$Yy2w?4iU}R zkl9Bgtu|sprIN8JvK~!MhBKEcU9+LRNbBH-B;v<5&@Sm4zt@2_&gk#!-w0VsJ}peirqb9VE!H8orEVQlcW}e)$DttU56U$m5Li_* zLs+LBIvHEuy?t7qYPROmf`v4a_60TK?0=4kg0!cy5hb@Ze65A7EE{ALd&a{;Mp?|n zs`CjD6B?j%>lSG>wMoatw7RNLHDkv3!y?n>gYsqVa?XD35<%-Dbgl)5^8r} z#kbF2jQn&EhO|f-woxr_<>ut<$Y=AJlT99rzGZBiWTTqV7RmEjixQtY*`noB8m*X_ zENk8rZY5^pHu-8+(U_arkb@IVxYQ;a7Pd4rV8LsYp2X9Ow@(LW z2H1O-vyQDc(W?#C$@Pw$vdp>N`xh0V>BuIPtxzyyoIMLTWqVALiNbV$meqJhQNjRo zOezGBS`0|+XA|sF)1UF z78GeaY!N_K>8Y!Ry#yHg1hyJ~4$7IZgW^wrz9xQzBH4K9?2o>)*q=PvPhH-D6Dg;w zKcazks`JrAx^pHokGUAVou=BbAY=>gpZPyr@%#eRrP$Pl!9mIS$NR|~&`S1!+~Xij zkc}(7Y?cHwmD9*LdIL~qgDr^E6+eS>8VCuwwqIcYGLWu>r)sW0kRfN*)t(}t3A+4 z0;wy61mO-kd}ngA1Li9IC_p&Kfu}1iEX9xnM6!nf7q7#ZF{MR@PtW7iX50F{TQU)BUZlDdqRe;dXA1dkV4HG-(U$6QA#0?gPoKi{M_$5x`Ph?g>I8 z7N8hY6rWiB`_J&`z=J49v!_2sc8&H``<(OKE&ka2fbw1GpV(iY4zJ6r)YebD51(gu zhlkSVFPOkSfj|Zx-W$A7X5UR_wE$20jri58>;R9ehp7*vhtel6#5*quA82(w{k7Gr z@E-C3P&A3!<2(3k!f^Q+5^_Pg`y2a4Ym8uc*&yu$WL zgGv0uKG0mg-0!1YTWGn*NppC4i=}ucl>pv7c!IeoDkR`C#w00a1*1^Ys9C zbUrsQu^lAQr7$D#;zTK%4kWYAXhY-#27r6d52J!;@%agH{k<~t91p!h3P0Lj!twio zqa@DA0e(;EwfQ$-`1oD0Uyo`e)DdbtYELInxR2p%>^7itciRUJU(j!iM0`7ZzAY~+ zd_LcX#^;Y2zLnK2ueXyPPlLy$HtS)ck*}?*n$MTh-KoZH-VIa$z^g6CAG0Y&Xj3!& z`b>6l3f%Q@U_B@;{-WvMsFU@QP|u2XPV=Jx8i#p3k2)Y%zYWH)eON$!Bme$cz6k0( zo^El!xOC6u_qp~b4*I4qD;KAbWMG_OnPPCJ(PI)UXGUXi*MV8vCodNN3rH_K!9Ah0 zqZXAoArF0ElECl*vO2)+ACu_lxrukZxDyK@l{JLNC(7q|*4j-j_XouCNy_#^X$qjC z4rp`1I9oTB7DXOm2>HM(S7B8LU$?Q)jCc<*yS_}J2{2bYZ`ecn7DtQ1FB04+7nuii z-~EyiMoUnlI?nQ`kJ4|TfIjBP=J{kYF6)8lmu3qM0?!q1A@>6amp*HKs z$s^ic*hq|$mpx@R=$~Yfm3Z9Zp~*7n%_?5R}55qJ}aS2qYFjAkqQd1Oj<_hYuJxKw^HJjVSPeV_1yUn8PXD z^hx)tnd&GX@kiF8!x-5$tFTBT9*}BEG30d$rM`ktvnvO|xjd4^N3*~wQ~S;?vI@1Q zQSx~l(LlwEC{@;eK&%&+T^u6*-nk11Cv+l>0UDJ%&ydhmxr+iK13sn!n*7{i8ZN|O z=(PDL1Xya0ixmb9!vr)y0?>S2`TB8kMMrsDktlNi!I!2s4azUmY9V|+)5+rO@L9;2 z{lOKt+q$vr0@sr;bJ)oZ;qu9mFgtH^vs@1YHBGDIg@YT;);}NxpqaZLNWy{*puyFw z;rxGd*POg~(W{@;LLsWFH(VLC1Xl)c@UeE9C*M0K+hdT*booOwumu-6Yg*8BAzBID zGLXkzpj;cNu>;ns{W%&mL!2-gq0&`PWc5NOp5|@%M`KrgGcL`M`5&wgHYj9#@WDl* z9d?<{`(sObTCh0R?*mP(cE=o+A*w8{1~G#iN7G3D$QsAD20*wHMXo85KPq)cKRzC^ z1V;sT&>Y7s+$tt$Fgbiv5Ew*XH48O4ss2Y&84y{bxS zJkaXq^t~lMvcNFpk$0zvs?fO3{#l3;wM9=EIMFt`DnLssW`0Y_8Y}}P50CCrJz};3 z^oS_5FHetN!&7Pqa*~{Mv}oUIQS%kM)bRt+TL(Xm0NdIlApCV8eO_}?xOfAg$$yGJ@ zLY-XzndT;je=;DI1P3W##MRae!G*gAl4Ppg9*}|b#MZ)qtpPvmz(J(A7R7J)P&P>lg?eyh_m zXDHqNiETPRR?C=9g=e@OWd>LznNWEGSMZDZ#4nn4C7^dcI@^Y#lhyGU!$0d4kjOt1I%1TzYqu<%<--kt7O6TF#k)c_T;1tC0!0a#9T zuFP!l2vVV}u>;wcQ%|`!!oRVm)Hrc{`LQZ~YRQcg8kaagD5U#!3YAX3$RmxFzWbx{ zNrGsz-Yuk}F0Duyk~V+uY9L`W(m=-p23n#f<(pt}B=Ol5QKg=ZBx(@I%LZkwlE+44 zivS2Bd)rQjsMXAJo!!LK9t>l&Do3K2di0)@6^e_pR4fTR7}s@;NUN;h zA-!C_b{)Ng2i1DCTD25iBI)**vxZnt z5*<-oBpTF-gu0Xu!vXIoPJweCgwq3KPuih9gr!|WFBC&o|01Br0V6Yfkbvlg1RT?B zw)iHyqi+3;;oXUYcsMWkGX-?Ej32!eU^%K>5uJXp$%{KVoOZd>E?c|AT1&508;klz z0y#>}?S~GY4~Av<)>4T8s=K~w9f-X)-4&uv3$ed0t|s=7iJPJuYu&`H|7+e53>ay6drZO{^_q%wNwYEdxy1caWO zsFRgZR#@$Ul~6ha=6jM=W-0R2Fb~#04n%*rT38dudzN6@M2!cBo#qd9`-r)70A4+L&P8^X4$I0k2*0!7Zee6q*Z9sce4ND`zHYqHTY&pWB;0JoX_!2uRAPk|3k;91gDAWL2`Gp@6&h|2iFx`NQ3 z7#YOK&868;z?vtz&kDHOt$cj7VUC)CER7*270p(;U=h=++|!J@)B&kj*_IcE2N2a! z?t+Gr+6-%j`8HtyT1+TCvxm#YYb>V zx@9GZ9WUp%%nCZFy&IQnnlx=TnC&2=B(LOOV4Jg*HN9!3evQIzsjV;#CaM-mIBUp@ zaJ>SO5Y&OO4ux(wUbg`v7uJ#H9)V!QDtYyZsGH<@WN2R>-}v=ivhk}HibqIKM{Uh1 zw+NQ4SJwKW#_8upjep&0?BDt*BR==mkyNr(`7uNzI%DE`GCR|7byn1iU9205Pj#?huj`;t(FN!^WuKu@E zT7>rLI~3YgeRg0`ESFO)meDNOlg!ys%-NI7*wM|FQ%sjpOqY{Q*ilXX&<=OWF}f*J zKAlq!*wOUoXa{d91nTPh^Ok+o<45$oqL!rJ9S!osc-ZSNdgAwTouv7mC?h* zMF15=S!3nw^i2I){7FiLrkAiuk{*agJ`In+^-8Sd&M8MSQ|5rEtbp;}k@2u@X!}WH z!KPs>lDJDE7iXCkks?o2hCsagRH;BM7PS-~JOP=a%NFNXLp5uu#<4BOEt$W%!caFn zviC7_K6eA`OI+#c6Q-pm#U<2uQXImEHd7!~y3J{BX3dQa?TxkZcb3!dmB>zl6C6di zR3(eCq;e{#8PI4mUi)*~jyGIWbp_Kz2MEw|iEgoPDtEC?W?r@U!I!6W`r+`jV!q_Qec@OUGm_66cX>;JHlIi0-tU3UpOq~eRf;sj zJid(ww=}u7VuFwzM%63xj!r@~jqX2DM{{Ny$gE|_F>pPJooFoL&u^2Awf%Ly{igz_ zkJ4Atfd~Lln*8rOX8u)avi^_inE5{!o&Ga~w|^BR|NkO4{x>S*|GZ!5ziW}v(znMJ zMeutr)o7(B7<9}M0h|D4lCwa}m&{ZFnzd?fT^|sic3)oSR)!X(qVx*}s@Op!MA#-s z%V?7|>gwBMH!^$vTII{#S1J>k4^z6HnEE=Jp1PQD4BaR#^8Jdt9 zzt4(TGD;boR4Nw=zHG-TeGeTyFY=UjP*+JGy;fiL2;-{xq+I3^oe8k=2-v1gey0J|%~LpO*a-`CMuG}04Tl_f?%Htv z)}hko6tZ#Cx=st)4c32?nTMYh0xvm3yqo%iP-5YLeG~bsg}M+qsK&Z}r?XyFuxMe@ zELtiZXx`(CM+6y87uJB=uQ$Cdh|L$2~(XZ2$Az#kq2IMFj?&&RJ_==1^|tO>Cd4hJuLT${#-6 zd<9K3lVEwuZvUvJp#1{C=2CjM8MW0U!*-137SlbR{iR%@c?ZYRqH@Rah2bPj+$76b zK;WLQ%p2>6lz=$jyt#P^rEv)Y3Q}rNutRUa4e6=02iaqBC&$*^xSX1Rm1b!7^5uV%)1vxFvAjX{O_KIK`Oo zkF`XwYf%P)9sFK|jyG%?Sma&dy_MhXBoS{qY3@ z!tOj_nVu2yVT)Jalu$8McNxzXm7BIrJMxFb9p1q$s=4xMr(|kHb?I={k#t076;|oI ziyj2vDY+ke8hsLm932`M@_#>2XMjur*2b-yZY!0#*r)bV+`YjJ!NlCU!WF2V#qEXN zZbHOvgDoqQ;WCDzBqtM+6PprThV6o{H*yiD>@P45o1=_2BS zozXH;TFQecfzU z%dXj6u(AEAk@_v6QNXSJ$BvEN;(o3A9RGskeB8yy*lYjoZRqi6_~C4F=!uoG(}e=M zKV}$LQD`?;JfasUqo>&ip6OnwV~hviP@uq`o9vlr9RPBHy$V=xT|!MrqM=hR<#5b! z0H!kL+7$D?GM>vtOf*48R8^7*MTHEs8l@MT9pG6f$UW`#gH3{DVRUT{hFbrU&S&o`WW8u;3R>gye^_`G8DYFC2~b zuTVB44c}brFTV&Y!@g3cq!T@L!;!r45CFF;hpOHXgS%EIgW@Q}Z9^c02;xp|@EZ0= zz{M1EA2s)37~QU;NVpawFT<(9@7z$^%6P2#GLn&7&P=U5u>e{qt(5L!IaZBaZ{DI7+vfH z(LDhke=&_$vej@5%0~c#5K~Un4I%qv1@2<{^mJ-cz6gmbgcs$b2IX#i~Hz zWj?CV`RNiPcpBqJ{f?)f$6}pkUN)K>=vaKHSbWG(a-H+V$b36ZqEKX)l%{taAKG8(T;W~0QIiAhoIua6RgWSD8DVS}i;4_H*ZE@sDuW-_CN+SAFBPRakD* z`K~E5o=_${OXNHwj(P57JoF^ABeJoLmann%54a z$Cz>-hjTwoKZbCR?>cIUZu@!Cm4_!<8`)QBE51c{g@v2aOPl{vsQxz9{;>Z?A9YVM z8IjTt_SS^r-$#Z28V3D`AyodaBclI|;P78z!2gJq|CLPlf6t}+-x7fTR|#6MpX4mW z&+(7>qVwDiM>2)%r8~E;R}4@^DCxqNFphiBsGO;hTUkj`$^|t+sHaAyYUFp>Zv&|_ z5g_Hoc5aLZqqpx54TJ4G1>RL%?)k+}s5$IQ#^=9nVO}6Xh$xaF4N^p#F`4Q3%j;QcVW>>uAYzj5{Oo4Uy1Wx4M^pPus*)Ai_sP|(4G z!YFrHTteZ)eh3CU7tLO~Rhy92f*5)aTHEts zU*F^}uiZW`!cSlFtBnOw_E49fr9|?;6|ClQr|>t}A9@Qcs7@aTsj*t!d}D(NIrKKx z8NVJbUdC(nc({CTFB`>;!{@tBJF%L#8NK^zW4k2ehem7GU-2@AVAeO~tUto1^>KK; z7*kF%l@<0x^?-^C!_3W(Y3DIJD4Rg_^(gZIpsegw?4~@ ze)lI%NgfltUo^fB=lY~v!oOV+x+FWE^SEsK{^EE$6ujOfR0G#I^BO!K-khr2=JoP4 zrr_)mVNpHmYSi#!unFxK1LB5l~4TswQBtE_5sW7!hMzaDt9gww37h-O)+ z#g|(TA_RaH0L>d)Jxd-a7nSF_{?^A}`+oS+|G5L{{r%7Gp5L!wpd&ze_dkz-2a{eF zm+#)pVo&o~*4hDVy792Hu6{YSQF{ZJUAY?8Jf&@S=z;YzOkGjE7~ZbLchUD(vQ$gS zYVR+LXs#;)Qz+i2Z%KvkFLM9yZFGJ?{Lk@sKlz^r*NvXXhaq~hJ!gBX<3z z%!GvhwfpJk{W5)XA%Fd?o-?02FY$u@a;zU&1E2kkzx}QKwEG<>9w&^2uK6{Vd$0dh z{Oh!zf0G{S^%(vev*AM>0eAJd+xvxI;32n{MUc{i?px2~ZTEYE;57F7yPF4}LEUdk z;Gp#RTW7(W=<7IX8h&}`i;`>Qy;x$dSwD_$;BuzQa=cv{CVO=)q1C` zGwE$}y#CeC-LAbyOlJ5`{%#)u>5*g{$F_^t>;7$|`4O(hr{<~glIPb+X5lb>7ndEc z*WF{`abbcok}a?2$KI-aF5m0fZRF~4(c`$dJU;K&Vd3y_x2@0Z#mQ+ZbNJuKk3ZWV zd!x(M`-SM@`uwj(WRT4{{I5@|w}nf$soQ*C>&Jx^z1#dp7p3N4L2(e{b$*CYSBrRA znfYF--UeTYUVJdJ?=}pilG+4D;a@KFO77QTy@RU`N*Z&#D#sg5NM1l!Nn?ZXHxI<; z6xw4-ymvi9S=Fh5y#nNP@Mi9{ z*I=whCT0%3j1|W+d2C*xo{ ze=u4sl{^6T%rL6!4`~V8ziudc&=(VN=HIU>cai+|@Zw7;a0q&Ir9agQ(k zdi1m$Ca1^#AW)uufL|K%Svj}POzb%WZRgwcdd2w?k*p?NR`<8s$;Pg@cfE$it(*~R z7Exva=tY9#Hffn4eDp$nQ=jp9kS#B%S&RG_jJhHG!unEy(z#yl$W&S_kzIQu)(i`G zqNlEIq;c@Fcr{k77Fvbok4>zv^T*?#Zf_R#2_q|pa+~7^ATfh-?BYLLu=)Y386GcA zclQ&=!pm2gQ|A%IRv17Gzrp&uFb!8HBrM!FRzu*c=NoIPqrwibeV$hL5D~Z7Iy7Vu zdMlmrzgEp(Clt?_9V)0ObDNd4q%>g`KN0f7$%`jT4%5kGSx91g(AGdRnyh|LO|E;e zkXy76>wJ7}cVn9~LReN*Z%_&iuQYN7vZVe2543}VAa)Ml-x?`})wLW_>=kftGe_?a zT$x}YJmBe&aNQaw?aD=1;Bo!1QTY_(t}|B(yY{dC@-3Ha_nWkY_7WXsv(TN@ed&_O zg zFr6_o!oP-l+u@eiOHCSi+>CoZc2@r z5UaAm6Xp#+^NENAZ6%F-hETIyKZuMPiE?9Aahf1M-4YX;V~Q$oTt(@;m4n@rlS@_Q zbwYDrYrS?Oh{dFV>g=i2F4bIZX#a;H`2+p^kVW$eQ>{QBk|RLO^5~$)ige;pPiVfM zEMAKl9^EMT%?A;Wjl0(IZpXUcpN@ojpEm~k-o~0+X;eVBt!D00cyM8hVN^a!TU$(> z2c<@swn!#Z-#}6!wl^5Pwi-Jp+rLLq3bTH>Mhu#iLzPL=_c8>(>=C4S8{22Tr z1`p=;Z3~HGJQ+GLqbuwCbWAS0c40F`@KnFypliG&+hXOfdO{tpoUE z85ec{*kPOdCu|gva=Zncv#@6B??E|Qnv?Yn6>FbfPoI_~1zd{ZWr(;CwqQ{l9hhYn z%K*pB-+K-PG>~Npv9Z4h!C1sp8CPL??q=hmw^cmP8BM1N zM?e8rnMRQt1wz|^p1DDlE^vi)7;Vr+{x-1l5vJTN!m^}!$XOwB7%)h<7qR?~grMn! zbl5|+TrV!5~x!lZ};;ee1M76wZ6Vk$Z`V zvWiiZLp>a1v_w0|NvP1$htoJNn-c^zY3gsLh^%4U=qRdFdc_OR%m7W&cQAyUNNEM( zs?|kf&H>>DNz4Jpaj?%=p?ZmNNtv@ePYc<8iv+dq030eQ5oamGXv*8(%#f*F`R}^{ z53j^(0$~%^)B1z;y58PF6K{I-Ts2uO+} zwD>XJ`#ty<%YsH}9cZKsaUF0diq6g7Q5nEEU%MNC*~}fD4md`0RrarJkfR#5b2t_+ zkrKFERu!-uTB!d3V4S!GsLSA>1!wdS6pS5`Vw432=WlSsa>X@}sixAA(>z9hEmId7 zu+p_BO@9U12J2QaZ`b7$ts5#Q2X5CqEN0Ylm?@3@@&*y&z{Jq%{XqX<(AW_VSXhMC zBnqI8fXo56U#`Zt6>dh3XpLPVIh&X6dL2>@w^bZ^s$rVYCiLN&nY|=^Sb~s?0SP_l z{z?y7&=Cmx1|5t-d{m^xjv}6uju1U@3^T-Vz9|MO%+pDYIK%$ICQ3BG#ip&C;HhXxjG%=(zX8-t>qGQWqPYk$(Sp@9 z&ft>m(5Ps2I?_Ul=>@Gs(W|K56a^sJr*W5=Nn7D43`+|iV;DkQcYqi%pn4sqelsN~ zMiCW&&HBp@Xo1zH8TE+-029w@H-RLjl=-10rbOCdCfq!7xQT@4fgS}A*y1j3fWk(A z{J|6zDicTp!Ah$8?Qoi%5a7?yhnQsvE87-SlnE=DJUENR!FBfN3wk+s*{uy4UovN` z5V5aMzrQpnN;(A$QwxgG2G?UD%}Eq0K92AUI6(*>Tv{5^0jEUwKp+^%5X+f53xHh) zylxW7V@F&sL>fRQTF9EAM9&k3Inu@T{y4f0+Mg;xv#NKvKnh@!FrEWQj^XLX?*ijR z8^b^6S8ci&nsY?B3cv-{Ic~=W$1hE1=0TdPk4=fUQTxQr_!MarONf!YoyAPE~p(jrdB9KR-i zrvvz1?_3P^YVPOMXwJM<+{@D4_QB|Vb9JgfYod)FeRPK;6k`CK@&=Zj4g%%95;MWqXEOQz2rR|_uz~4;m6Qo| z9c}40+NSTxHQ$&Dm{u8K$e(_AHqC}rq5)HiRX_vpW(BRx8AEJJI!X}v`yy8BNNTBZ4GF4zf%?txj5wrkmK8H;=|w>@ zx_&lg8ya#|Rx-_D6AvOggM3?<8K1#;zA#Pmdj9MCD?poBRITjg_FgG*I}1oc12HSO z!yB(vG;z$zYvp8jQk}OQuS}jmbqTu3d1ds&nOTj<-WaUxhlh!q zk{>i#?^3z}pRBf7WZ{tmaB&j7P8|j&Y2A}ZCeiHpfMmCQIyqK;>0)iz7L<|kD}Hfk$v-j9$(Ug5&)W)Wq^8S=VZiG zEszg)2He-7^LbrnhH(Y3{z*7M0_bP+goZonwE)4mogvqeiut0K>P8FNYXEvE*<5oQ+8~Nro%t@cY$hdcHedKHc&hV}v|O>Y1;Rj6INy zS@xY&!d9yV9XS@d)&^I$f^vk?smYYlV8D`$^|bRyGQjgyl8Y14^&w9q3_?hjPO-?t zJjw9(fEp{uoed<{TAdmVXcgt(g0c_=LO~v2EF@ru@N~lfWt?{Lg;|_1DryvZfsyc; z2*ts97_;@_S}(gZi0ZWjf4ptfR_JwwNs)62x^sFYds1Pl&%q_g7x5)c!eqQ&dn)UU zKuO}Lfsn)_9U;Hq%kKYV_|rCpm7gn_rMosMnMvC;S7f4RfIolBM7s9-@*WcT6?j*A z{x&{y2F)y<2?q|3L!ikgGB*sZto+eU5Bx^3r3X%i&FdJJU}+07gRO`LCZRm#NGcr# z#o&*IbJ3BA&K<0Qz8rEJQm~wY!7i&E+fy!_ue}*@hrRD#T#Aehi+&8ZhyOiIb5x0> zc}Li@2Saijo;0T7P8lW$-~%0tI(9l70Gf`NBA;IIo|hBy6OSm4jTDef4uIHn4=A8o zn|i@trUqny(Mzx-xR z^_boZOa@z$57WyU#;A%S>kkfqEIbp!*(oY+l62o3(fnSjwSRG5a8zMYwk2tuhqfFa zB|gJZL?{I!_)34Q6sT*en#1!Lx$d4>su1yVxuRMhHnV7{m_X!y!`O~9A^}$831MD2 zI%MNTb{N$}^k}l|(^P|Upcp$~@pHp1D}`_rrb|ncx}yX!?~$S!!1a5~CqeZ#EG_bw z|3PbY4rwonPg!+*04q}7|`_2gqISa%B2PdLE zrnjr!k;U_6XzMt^tXRE}Z<=Fm>(H4~hd3HsRXGv)&}^8+Ta<6~M|3YPzh`9EQ$8lB zn|13!F*I*J6L4Vd5;mdeyU5x_fyy^A>U9L&z`M>Wv{S&Yb~ed_56MfN9;S=N59g$o z$TZDvJ*6GUy6;w>ACw9J1r&lrQ~y%z#$f=3B(x{!hGO<42|55^Cy5P_p|M5`V;^Fu zboGO6#ldX3toa61KAD%l9Qs_+xefD~O}GiVDIZU!ZwXm%UQ}3&A2sP$nUC}2vm;L^ z*OOYo2PMA>1(_TCzzN@r(M2bRg0X=gh>?+Nw#fbw>KMGRDgWJ0K#~$#j%T3zm7rTp z$4D%KEo!b4f+(5<1Rbp)1_ciiH)+sIT0O$W!SefNMR{qZ@fg>7eNF*GXh^e1(fjCz zqs6FOk+;QYm0586T3atDk0A&0&Ut(5ASHEHUaM*dILPZI2L`th3?YFCt{$h1PlRl6 zv`T<<2z|2;I?P^XStfp02Bv^Y83+hIbg;$CbxskH?SEEN6=?x5tm7wI|&se#G|{b*Td` zo607o&RfXMQemzj9W!P`ObH&46nh9K9q_<#6yDJ=Y~cvN#M6w|6ooN80W`9Kajdu* z(^8f$^%1MYnYNgLBoU3|EJ_);F*+I+bhFreF*XmdEkrgyU`|Tr0E3un?#~Ecml&4T zSdx9K?YCr#J10@Sg%Eq+oA=SITZNVDja`p_?vfq19?7fFIdtQiZfG?#3=n?avXc)1KwI?x>C{G;t3OTh28v zi`+)nuk;@Cruob-?X$)<(@CM!Iyp#b10m52uUZ4WTs`m!B-l{sS>m?ISTQI;rEjyJWw5B&a2RlNVRF4sk ze_@H!iH5qzVX0a)GdcdnfJ<0|NKEyw{JXXwiNXWEvzWt0Jo4!-t zhYRjSx^ML0i1>^JqSK=qTs0j(ah2Ies}cf}wSa>tm_}KM71_mrikJ>E2n@}kB=DcD zw%qCs)K>(Eu!vgR42ish!RD@AEp^%qu4RJ(TGUU;oC0*wNyz$O{NYup|Sn~6lzVqs~E8Yfb748c0cGQiv$CTaeV z+_Tfj9KKGFcArA`OzsaXD<+6vD~=R9 zeO%v5e!d?x#r}Ov@bA4N)Q+T)-Q?B7aCRy-GjRWVj5YLxsK_h*cr-{kb`&Bmb-HWp zJ56&(V$M^3j?}B&o|D$T0u{Qq9&@{u6S~t;pS;V$K1Mxte`Lz^@xwsHNlOj)J7l73o$c_C zOOFbY$<^G^&*}j3C%W?z&W!i;;F~x?vnL9EU7o-hZ{t$hIy`AK%m$sq^YR5ym79$b zgO*k*ucx|1)Q?mz&R@FO)wvN~OiRC=${_92hB9v-tnO0pAp2YG7bP{q_3dg+sPwntUt#%wjH zGMlpWht6&@CkGQhFa_)<5-{xJ(5QSW5KC#fhYQR|`76Wm?b^V(y!urZM-X-9#`H$t z2mRYCStSJPW3r$+!c(yi`Tn)~Sb*aX1M1UVQI_p}-%FkZmZ&_s(rLU|ForASbRSg~ zN>HsU{t?R`4HD3XQNh3XQsz$&BL z1uBJFg*e^JBVb(3%`BgkKIVgDZ=jOvwFVbH#97x%!QJYZKS$zOkYmy zh131?I^>mhe5@}PFX9OLoZBP{B)DUy}q?g?KO}C zrVz>>9{02EH{P{^k^go~fVtz189s?V2>Tw{ zDX7?fNO$7O?-)WA{F!v=p5aHGZbyMA$V z?SU~uHxRnqiPIwljJ|8v&P{vcvbJ@@>}T89>1C4gmaPvH?8mc&51wYdK~Io9KOT@Mf0@pUabE^S2x8)5;vaY-JNRe-y@muLfzM|(omMCZ6SKn?o+}m_7 zU7OY~>{`|~oSNDW>@3cyRGJo+r(*hIP0wUCCw#~ zdbx>S$=dS9+Pc)}*r@Pq(|y1#aBDifuv=K00HCWhIYZ|9%K1iF0&kPumIRTiXFq(} zBA;EcZY~&i*Yx|F+QRI)zBy1GLZ!qEoud2|=H`kEweGNT3$f0+>pJbgg+QlI1no>b znzw!uA;mc{-L-t+++KeCornf~FEqSR?>j4h+7?DVEp*)bSBg%Bml#aXrT^AwrcX>pIaIc6Dy{FVx3nE{g0PgOu_Q4;?{nEB}KkcziMhu z`?UrXZ1DJSV{;nVet`Ci^ln|dK6`6*uDeS-$%1qJd6&`ts?5|B&M{>G7!x5fdWH)j zwIX!ePPLK~qJRc2~(q+`*YA6oJ=BmHWJ>$h}P$p=?YYl%AmYp0|Br{g$a(q3!? zj*byRhR5&bSiA*7n4`imS@I_RNL)e_v7so-q-EZn>9-j#Et5(?>UK@Nfigq5aVlMZ zLA-*@DYVSdL>|YYG{X;5NT{!b#70@a&2snheI0!%i$P7jFJ0ZL`-V`Sws0W{HaPCU zK-wd$PHjslla~Q>n{b4iUKgao;4l^pN|E28%@mRF)CYf!OzD)ph5eKfe;0f zKj9j%mgBl#NeFFAsCNc-w-l`i8?|UR0{l;2Lm7;==cuNx*r7ER8c9*md)Q=QX0E$( zG2A$Nm9F)q=y3c|NU$jtP=fZEKPhfG~jqS)mYh^r-Su=Z~ZScKRcmYwW_4|MEX}xZ`Imk6R%Tu zUf*~)OSr6MsUlLiGDy#arg>^1qLEO*_vXAwF~|GiSzI*v_+cTe-uLDBB!8&O`~La4 zse&n+K;WacQ|I*c&w_WxyG>#LgZiHv)}|HSnu+;RR=LTwKw&&&wkmbYr2B~sjjlKI zIlSo0!_DlsWKIJRc8xXX1-2~G#y5k5$q{~reF>bg7o3T@>qdmF)zb_G)~mZ7J+CkD zi?wQZM9OjXPH%vi)iKRt;X#$*hlcLC^Yvc0oQ%@w^2y{x3hG42QI_jY+3EBrosc9( zIoq#fs`5W1n?hZWac5$}jZjb~RU&Bm__--7K&OCl(4T6s z5n`E-IwQICDO&Cp@f?tRSVcmFLeAI`r_5^Gl<)_-eM(VP zD5CjCdP+gqP*y=Gx5_j$(PXpMF`|IaaDQ(nhgOLEbdRFU18zui@7{H=oxtA$IA`6HGCqgIK zjVM+HC3ZI1xiS9TToY`jaOhcM|M%^l5p|0K{D6Yw8G$kESvQ0Uvs2(sCW;w(KDM|R zLLNv)SOdHP%Ro>#D3nBA(+`*sM#~6oXnn?3Gw^|>y#q9g0L)aVfcl^8!F@})Qb+!l zs3H)(If^0S-mrtO~T3EKVd=*Oxqw+2Yph@6;8gke-=Cn`Y50k?nND zb{WwT);)&70p{2qSKtfV<$zso&tA6A zZS-pW@=;?B9M5`~cP5zpKMCAt2Mb?p1E@%rptJk&95yS=Gg(9{>QF2tq7Mhz&N>pX zwJq{kk_v)NV?n`4BMU(jAVfP+Z5qI{C*)b+vScZm;4{s7F19H(QFua;T@lfVx~+IX z#8SYks8d-8>6o zuHbP~^Qt79Sw;=Oh)IIHNOJb?kun5LpRi?#O#f#cGM4s=yl90APxM?}(uu3ZNZo<* z4)cKpDN51IanAsWaF)s%u|-e$wEOKEFHIhY&cKNZg+#{iQdcn1RDGZ9Iug!xE3Xvy zz0zU6z)VEhF)by7Bi%iYSsC2`G9_Xr0<&HZdvxx*1fc4OLw%6)uN1y+kD-EE1jinF z3tLswLYhg+9zOpJ71#nFRxvS?G(_Ez%L^1^>VdNPN(t=WUNN6i9 z2cAnrF8gkiH)?=PifP?|zg`jcBC?yYHhh-$c3#66TY3Dgt-Y}x7kyMdLiZx$?!>>x z1!%8~R@c~`5l7}OKK!Br*6g7ADIaKH8+7&8;6ui@xE~4Frka3oV=?+?5Oa?l7iF_< zjUy~W95#$^>klpXpVo2*$V>K9HSpWCcY8J{iI(3CBd+1Ta?)$g$pf$MH*LD{u$@R` ziW(r^&G;uQal{3N!u?qZ>%n_1>z@=dIJDqg{8CKKyJ5xw+>Mix6v&|EF!FU;nTi6CdUG>5w!j{7W|L$oT((~phE`FgXL=bOCzO>2U&jz# zSKCL5)mjBlcs06+DbC?_IP0&o#@GG2jR0N@h6f7g3LilXp^b2zVK)6>*|+F)R8pBs~OxS>lXoRh;|@a0b+?wJQBp=NSn3nP{5}wn?K<0~fCMH8t*m zp`86?_`c=Gb4VJ9w{|b~KE44mM2Ug!pgnL%GA*(cNDAZa7i2UuX7queECb7Zsd{0S zUGlqm^F^IOnL?G#Q37<2>Uh)2p64A1Gx=y%vQEQuk*^@l#(KzC5Tn~8&M6H0Ps5nTsRF$0G zV3YhLqXZH-Mh@{_?jzb8-Al^9Ve?i(4cjx+6VVVl#;)<@G1# z!uB$gLTgx>LVddhYoEyD4#0Y7&u^B@WmFqliHl{-of?2i%LVdcyYIFnU ztuuK1xNZ+y5U6T4T#BUKg9R{? z2@>7x0-=7f=uDB`^1e#(B*bV@KtO+$!W@-?U-|!F1W?pCtOneX1BA>1Cebrcz+`wU>f_g$!I&d!G<5-Lm4RyVafYyBT-BSjXzW zSO@xP_dl%To9h3?I*8}LSch2}9uHF<#f?%rdoRwOOKU5IRw&qvg4mxPPOYdfGZEFF zV0$}~W~9Q{NDh0rT#%`D6rdd$W78V_E%_z>AJ}n6u6bGD77=lNDE)O&)ELsd-rR(> z^6y~2`0%pqy9I22y&gSMZoT4YAB_Y{W3;yy@3wsJBB>0UVqy*OeLnUhlikJVfN5hu@ZoQ?S8`8?PI=vElcH|uyy8X-spfyxNAr;N&=nZd83 zo)Bn?c+sHzLq7VZjcvK}KnMDZRMdWAJ3yG(u02mud;7IuUL7zCL4?!TR_=Qgp^tHdJ+@ahU zv6C)J_H2NADj!z}^(;_M6R0^?gM(I0$W|bnL>?3aZCMKz)c;{0JIGNSRNG@X(>!u{ z--X#uIFuCwW4+eel$9_ST|25 z%b(4^b)eUa2K@Rcdp8}CG5?MA7p6Wy5X=XRP3>~v8o z7-&V58?|RR!EbVh?EnpFe84k#emIH=PEfahp+n}v@CG0LIw#_xzHMnF?-tfmtgoZ@ z)pbFlsh^z7+Z}WJFV{c;NcHGj zIX{KRS-+{dvz2T0VTp$ci8X;cIzxu2RvVXJBiq6^60J0@g`PjXJQ~tRFCVQUFGK49 z>0`5x>0fHf-tL(Y;r}RhZ;f-g5;%_cMrAXgxYq)Hfv&KEdh)K+Zi-} zCh%^$a)QbWF+R0M(Ll&icDDnVZ34#Tsn0|UO%mA7z?DS*RVs;)`h)vnRuUnE26r6d zm%sGCDG1XrWGqeH0-GgYNjppu%VXP71Eqj^yn{XfHd~5j7_3XGsLN z&yWuWwd~y>NXOh{rbPGgkk2}`iSXU@YLgym0Q-f_```)^{b%YxNT#Je2x_k@1dzw$1_o8`FfAi&G<*FyT zX|JZgcHp8TJT4zbA;x~E$cLY2_e-FEbUJ*W-Wrj79DevS;CNwnzFi)CoF7M9BHeAl zQhVv>IlbH-$RP&PwKGFuXFP#)zB==KOx#h$<^+SV_Y%voj_NNN`d|JFe{=-E0-K`0 z@W=JT%gE+jm7gPf$R<3h!sBJM{=xmxk+kEHEfVv~;Qh|powbznZ|P37qnC0o*a*8O zK-%Qv+m0I+a}i>l#Q@S%-F@={jD6@6V%>RF-FzWZ-J>Pc>PMTx6CfQS`x$Kbh0Y2-an;1v_wnI`Q5)#^acP!ghE3v9r2;EtWuc-a-cf7}?dhX+pN+eK8UE%m zH_7?B^S-nDl4Y z^AYoyq4t zjCsQ3-Ls0zH~n5;MV4i+Noi*qosEcS^Ko(&Q7_o!M?i`sQ}objN$C6GHaFAuwugbx zZ`mJjP;vTgTx&bRPla+wSiXMJKWLpn1f9k*MT{F7UNFTFV-lpC#f!8VDn73TLq6*1aL;kmmIVwW| zUu6YdR~O%r1Q!T1%5XL)PK!=NHEf+neQS8tZ|r_h_k~xY0U3i#e-d@BZGYw^SCymD z`(3Ho#n09L5~=U(oQL{8`(A1lY_BH!O@aQ6w(;88i54j-?F#(1ZZ6g<5N<793klokM%9b?MaJABKuUAeuHIwo`#C}n)C{&u zw;nST2LP^7=9KF?prgAbx_@1K1{n}1<^KkbP=<2wGTTC&~yt(x*FX1?nVywNf&2cl>% zBVuQD*Y&Ntji)7u*svpJbX}_R`QM3GuAy4M9(AnKmFu+EgxgH4_KT-fb!s5UWL2Pc zbmB5tkFHpio|S1hL#02qI1e0+vvMa5fRFXM zP9R zeCL*Z@eM}UqVb^t;IK|qQ}Fc&0-gRfh7~n zHR8XlE)$&|uCATG%y)0j`+|X?Sg$AHCr@qm=Gxatcf+l2rF%;cGqQ@jxrYv^533yx ziJH^$hk+-e<%$LW!_p*>t63t%c>$kjAD|7l{z71aLPUQfrNki;cA{dh#aE@#o$XCZqV6+j8%g`Lm@@U- z>mEb*V8B3A2t>(67L2`~w@&N*eD$?j*Ll6^OsVULWimu@;h6jwW(F;$5k*1yT1(3| zWW)*NHHrr1qlX4u{C{wv6MQ?U0*6gy`Ie4$Q%&v8`Q9NA)|RLw6&e#|hrTeCbv*F< zEbXoUiE>RUqYk-(SB0q(rYwDX-7s!o7Mx6(d9Kywq>dn#HW?>mSvwNDiJE0YCuV*l zf->I5b4y@}bx6s`%dc1nrGE08B#r+Y)9<{h!AB6 zgRHa>&4U0LDHxo9lx&y)t*El@x!(M^GW^v|;W@-~P6&CpKmx{=UTd_^!!O1^=si-_ zoB$_Sn_U<`z|8G6b^NnCS7|L&7%ot87l2Jw4+?u|QlBaD9RiXnky?U1O1nR>dcFjG zIMz}zeopv1P_Ygcev#S-1ancga!2b{onVZCY)?Xz>@v>Lc{ue-D>zi?!_(y*^VOtj z%j1UDf4NTYIpMe&=br4G_PS}C?sNx^C?*-orI$md~^SrfS5j58y(NEDcG5A;h( zQqmyG3C9o#;H*#Rh1ra1NHNzfJvdUK* z6m?i}M&&po3F@X4pn&75C~1+A9X?7oIz!`iWS%nBcz?ijb6=P3?iRJ4r~rTwcKaIT z8p+U-;`b}cFAKk0&z)F3u=oGlAPM^aG)Vf<2Z3Vt%4F{xr{0(!DKK^@@7IkRCV67h zpm#!XjWJf20gwYcNbfPow8)hHkQDT!dY;9m#Kch!Nhn6M83fO^Xz#R8wbnp;&taP= zAIJAIGre6co)T9Gd|mhJiqB=;jo(dYK-ND^NM@@lF=0D1tl*u=10NnO#0FN%ew4FBH!BGXp;=poXh>xAsw)#y>pOsj* zo_(P|Wr$xRJv?C$CH$|PpP;*&8{|IzE9ck3|DQQOuuk@L1M!yg>T&S#q|XIVpBzBU z!Qg>^RNDnQQ`IJZofZr5JdG&pa5hxBB3U|jH(o;WT&i|krl!<(kkCe{caupaHoX?n zrZ;iQ^3MqhODb3;Q3$L@wKnqC0VP0pI?4XUn`LoF*MVT78^qsWHr$7Dh8_6e5A_GM z&L8ix1x1CV5+OqEdAlM)LmL;Fm2(0TmYKbm8poB*CnKbNzWQSFq_3yisq2P*wL|J6 zhtlR>a>=Xm_NC0G?ExC&H?rmG1~XZAH-yOwh?HOL3xI1(hQSm%BAeB_BXXn6!*%70 zmKd?`vd|jbD!BEklMs-BjVM>?NrG_hvipr;?rV?M0vNd>kdS1&^2pc-DE!2P?v27K zvLzDOB~F019_%G8QtOT)IZp@2jy=BqwcaFR@5#O%ai)vkxGs27n_CC9Q&b5}NDrfi z4kri*tZ4fQg5bgVg0NG>hUwmiO!~>7!Xw{r19oRnYjVPc@<((s+RE6 zy-I_h1pE41PIf`7Xu9D(&+lcE;mc3kp1f zd{6kDVL8Xz4*ZZtk^Nnlow0k`25|wAkiXWVb9c1Zj*_ID>@E**xF6?{i`x6b{M`tg z+tVz;rIaZU;Vm#afDxEcC7kFDT^y}RxubdxSeXt@m_|)K1P#QRBq{-)+xLOZ^}g2< zUs>aQGKSmB=`*Y2pSYFa2E_=)YL*iP*tS|A9Tm&sh4twwzmaS4qne!Ody$W1RQ79F z;Xyo1^c<32`R0-wstVBPkuf1!7|(eba`g3~^#@rAlCi>Gu=%frs!CG&na4qD0nG_( zXV4MxWj~^SqC$F@ZddX!e6>vk=o|8{k}M&%G=}KqAfAbQnI?+c{y@!87PM|P=qTTE zo|t~*Zrw0uzq89j4O;=xl>%Wm~Y`S!QHb&?xUo!I%i9OcbIT zJg!&~N$t7`xlK&fx=YDVmA<|ad}+ZIjc+^}XbC|a_-;nJ!12`sMNf+U`(k5ud;q=C zdk}TnBBy@W*A+QLL;(iGZ9zK;jhsCUv+CgY_Hy-~DQ;aJ zC3iv`>d^2IuyRq3F*W0KrX|Sh*Tfy$5oFhCC_{@cCEy|ery$92GY=`zNBQC(SX)0^ zj-c+E>aMhH!~m3X0H5|7aB0PI#~@?jC={V+i1;8~@zP{=U}Jfd0Zduqr>8F;x|PG(Yjvc$!gZ(_@-fnvip)n#R(Vc)^K!gBkCaMr-tcA3s- z;bFCvj-pSg)`YlhK9fdD^si|KcqQm6jFPOAnOxCnCSC$7cqb|*y{iv4q;E)HFr9+O zhOFovgH%jvkl^4ARW3!sdzlS`G3Vzk)Fp(@5QRADe{IM}#MzlZ5|J_NbeHrhm`vbv zLCVUM1M)>6xD~aa9a!N3sZZS8Q_%wk)mo5G4>-cGfuiza*z0&mlL(wi#`2}+DhbdA zNF?LUVL?lvj)WWs{tg!nKV#Bv!C&#oN={&9hk@X3W2pYQsL+8KJ^v^tv?TvlPIxdt z){$VnWnmu|fkTj!Flv+9da{ryE)N{g-R5i6G62ps&Ixd%YLt91cJCx+Zu)Sh0RxAulpjG%)p98_UmYy?h+O2NcQ)B^Bxqf5E!LU35dj3P$4Cv~` z^$TO%)~W-p9LOdEHiIutmp3TXQi>$@<1jcSp8K*{T-YhDdr;}Tq(8{(Fx(ZptZf3e z{Ad{5pQaf59RsR4Da9gw7k=;S=Yf*nr2xU;rQiEQ{0|Fm3{;ZyD)bUCT)Z^NA@FR+ z6(i7rr}l_c%}z~gjsa;pSKK`nN8lCgLiW#;pqt37j~Xgq6*Vw2#bdJ6q5;6Zoqr1_ zRA0i0jEoQLUFd&=lfr+5lYF-fTrn#Sfa*28s+=YHI!P4yoScVjkM!Pl=I>)^HH}pl z;pC=eM_U2b1R7@=tLo;zRXxa@YehN8qN%q28KUTw>o9I&#zl*Kc@A(*$bd6j43!G> z>jMcp${)+|K6GjRB=fX^j@1Av@OMGM+8BMY#U_!3!^(7#g z?*li}sIJ0esR<)Vy-N^h`5rQm&aG2d9?}&L-VPt~ScM%k>nn)p7>~ zJ_K-}$Sg+X=AF?4v>Wf#L;Mm0+>Qi!(BR@hx;yJwlC?-L38b3A~T5VQmh&4O5@4Ql>=*;cF6gEjDnK@AORu_(dUr%3RYv=lx?Pmf(dS-~Rf&Q?# zEs`e=O?%f-0aN+qMam(-_`D!Ud>*4563_2v@LYDB!m_)+$t{D}22Wh9g{u*v^0LCv z`JHW8Mipaa!KWvB=9Ck3`v4y}!{xjg)$LDJJ?NZkf82aDepkZSO`i8A^X*lb!?djg z<8`AZR1(HO847R!iJ#0{b&1R7p@Z)obsnC>e$>np1s(2y$mE)=?+OU#dP}K z4!}}&`Qi#CsY(?2JbH}O+LMV``0S^w&{w%1DKI0p!~P%s0x=x@#b3Ze|KTsl$^VVN z(CkV^3uj?@ZZMM8?tkQ(=B^eKfbnX@4Ot10Ud8(y|8O2GnceaF@=mx^!?3Zju*9!` zjPJxuCN(dHFDc@ff`d&76Jbk@?`Rc}g@JbnMGOD&PK=fiBRC<% zD_Is_BbeFuUeSH*-^YIDt3-FrRJ(fUvcN>OfX>OaD>SiZP=B9Jk-BO|T@AEXOkjLCFNSz=tk}T!Pt^Gi(TcCzWku2 z4H?6(f>_>ZOfCaMjhU((qPz_v;+c6!;}18#vFIQPult+$m&_ZN>&Tl=jVuMN4!_)x!ovFXctoK^ zf`W{AROVs!eAKqPrAGv0Be#Gu5#mg7EHN}8C=&dvWmVu}Tsb5Mj2i`hRVPajpoq1u zVmf>LGa&f<!ql~VqiAdOpTz)U1d zCZ>Ry5cUA!es%URVzOogYRJqG69k)u(-+k02LH<%grQ3-=Oa!PC`5unplk#WaoMPQ zXx^`76d6z`O!MS^5G7gG^k(c7VQ73U*iKEv-)&$u^8Q+z@hR@EcON$Y-7Y!&vP<5+ z>=F&8f9#UV|JWsZCxLyAc9JhwQ+?M4tC;uLNo=ERA3Q6ve+3k)Ec!G_@D@1nE_TMM z!0VZ_Yn3zq_5|)myCiPQJe)q>T5%+ATr6O2AX$LirxZ?LWBFhW4lqglnD_kLU$YpB z)fqDMeS5aY+Ty7x@IcfAcTfr3F4!qLIqOId(1+;VD2tr5?j|AHoLsU?;N0|M?-c+N zKY0=o!WPJ;x`DVa2DwW=o&C=G!YPtDH&0tB1s(nMvuE^~95zwHP zyuvUA1Fp;9?7CS)C3O0Q*r;(Vd3@SaVt8G+(WyP zXq@?6QJ`!cCG%4!SH6|$?H}ZF4ewuv{XdWkyQj{2(c{06i(<8=U=9QF!74vwM8S_uKm=sKkWvWBK!rZwg@(@6N^brg6&0&y?0n z<3+&>A#1;-6GEZ<9yC7yPe5gC`5RRF?rs zI+uejD|upv7p_8z+*Hk9C3XB}zq%svEtAR0MRZFHq>xZsL(6#DX#2H*EkJ28W{+QD zfmSS6W929Z%=WTVaAgcM*Juz$|2eJhi;p1GOi6ld<}lpcrR9|Q*cBwrkdO5dMG*OB zs!mM}J*hG!XVTV6Z7_ZEjNdA&U;Y`ZKc8HEQ8N`(Pk4pw?hagBpG!wvBGe?dcB>_F zx_Fe_lr;SYn+7X3TL5^oWa*~xM5QpnU8bzuLu8J|@NUEW=iulYUcr0h z(bG{`XLAmwKyi@R+fN+1I_$2^v*;X3pI`GTa$kkq-0TD6L!nI_b&X)0hVb&!x5tGy zS_BVqTln}#5cvF4aMUg^wtoS&)=%bq{KuV1Cp*1YOfd3hjNPiXX{yxajhtHn!#&EV zmX*WoWdlFMsJx{2bCF++X+OWGqte3!+8q6aD!=1AJTtfXe~7!s=-3)=U+~F}Z6`an zZQHhO8#}gb+ctM>+qUiG=6T<9#y$6R-|i3HJ-TXE)u>VRsXo*iYyIZ@&*NQzceQDW zR|A!?)99q=d!4kT=nQ>s6OX8rBJaKlrf*j#J*#U^$E7Eehob#xASq|M5hy<$4)bbm z#-$M*`g~GM>5w^4faBN)ZF}3R(61|)jvB!dXLCGsqHQc zxSzzepXT-eRz@4kxJ3XD2dH+1cWiVUOiZzzwqN`)U8_LOyc4i(GvkywR}9(P0`ZzJ z`6S0(4Ro2DM-V%Xu%Om69Jq;K%Vd=3kBZFGo#16%5&Ex1PfV~A3A#KMpKqm&B<}i} zig5*|KmS9Id$YF@wmIDCDV&!XTNU!(JfI-|)(IW(A>*?ccc7A~go^jqhyqi_797?# zDx@rsT3A4iagzm>Q5dF@L1L$6))G1i8i&o9*MKNtAM-;~T&#hiW4B?-#`zdEuf7(d zo))8+iNJ$K2XI~Fz+Y$wJSr$M-fkNDI0!M;1>xR*k8K@_zphBpyeWF@ zOR}v-qxSh!auBimioZvGe|#k7#Z55AtyX#43t#Y;MH%mjTlChl$^o>3qj`0|Cs=(E zYCk^$-s?zl9Ob1^99(qJEN!VUZsQwO9j{#@NExr`ex1O$VSjF4vqA&0EUTS>5GGH^ zcUYR=<-NjEzE_^-M%P|CXizOfMuf_cuSH1@RtYRWBXRf{12MktEi(@~kPoPs<&f60 z%-h7h9Y~7wW*+BQTezaC|1ji)w!vbn8^5?Irz#(*IslrCkfPA;Cv$kxXjNcFl#BT4 z&_O$6Od@mcXzO*Y@bC+PcY!KQq#qoEC zBL}d3oQXW%DMi-l-BNJYEkDoB%CZeCEcS|5ji&9t{Qi!ctphv{VAhH7?UtnmGw-51 z@9T#0q`3f#_oTJzs(m(?AGE;Wv_oJGCT^aJg5LTPN23uj@G z_DeIdxRAuuAN1GWE;Af~Ia*3_kugcY5RmwJupek#nGTI%dRX@Wlp@58;wVPh=qmc4 zoV*3U0ZA#pF`w5gER2@gGcscFiJy4s3Ld?HVmRWw#GYsa&SnD+nfm}K=~0nyaF#-z zGr02E@63KhxeWUSF*(v*3yxo$Q0_O_Jn0H%X$o`^0(3AIX$uaEzX1NpkuAyzgm+g0 z0BAY?=RFWGG649`{l6!sy8M5&UEu#wcAH8h0jr^Whl;1p`d~9bbN2tqqK>mYn3s z&A-eRG=`1K{5fAY69?Hul+*W8H?!@~IkhufuwRFD}RN0wIf zzBh=oTaNH?LmDnx;A{28!9r^rE|{j%@feMfHEUB|@cC^@cGLB9)agTYYQpsMdIX0# z^up;T3rpC7Aq;P@b@f6<%E{d!UF(i=F;YL zM>4SvA3wgiI{(uLYl_Vq2~p>J&h%88jec`k;BKzKI;qBV~j_5FN z#@mzJ)Ft^Rg4Xux>w-V-#jBiz_71QE4Cd!!-5^rodW@Lv06_WsUbh8Wj;EK=O;Oo! zY{f@xA=fli8S^hYw$77^*$ZWo0@v^TP2R3|?uUz(JlmV^AGKCJd4-$p@bP@^@7V4S z@Ck(dp6vLB>G^gQd)a^Q@%+{$aNBo1{jw~FJEzeoE_!;lp?n>P)5*wQ+ok1W7k^;6C@!l#$^A6RQGjEO)C zIfD_a&V2uU#rw55?Q?g@`swMKv+;SfUUT=e4f~Au>j^F9YV&&g{S6K7Ykyw>@|^bv z;yd87KQ45>XIr*6Xi4L~WUqNUzjsQWaW~$TzbiytalN%A3P0cBvbo+C`)z%mc1HI* z&2O&PmE1`zSRD0dj^`y)%rEs^@{W##mwFqK@bcO)p-m-m)~g`FE-`ec^u>y8T-Y;d z&mas!lC?^`<#^<}H$vV3KTl# zA#N=~5G5k8qe{>$*j~<^23$1mD6B@xU8WVuCnOvRqydydUX==|vR$RZ=LW>?JDqHG zqDq>-e^K-(0G=9YcWTSj8755bJsl|DyYH{v3+TX#sG}*MVD)8EM94%S&xpr=h>LE)=6wvm_nh&zeV-g>8K|GVfT2NL z!9#?#AcRp#8kJf2D0sF3TQr0*D*vt9huT4h;fDRYQr%T%d3x>^^r@k=bLlc9GHq zKq_z5tK7kkRyweE1e(@wfEPE~*^pzR_-HD|dw~ak;~a(7#2chjja19Swc1*tlD+rs60nx1K=j>ruCdJUo@1 znVI%XVpl{0j`E^bp&17N+yp>`A}omI?vRf)n7#%beA~^9eY#ZJ96ayf)!6KwKYhOg zgi}^A!qoj<6>|s(1=$<;;IN~K2>HY zHR7k;M>!`mE42=cX*GeE8>Q>yew~kkg@gH2Fa@9UI5aO?^iCQW zWSU`CExM-gO`R$v4&(kpox@TuuLLKuBsQbs{x;`fzvYS@8hkZg0}jx4B@YhA%E{WY zV_jdQnOg?s=cMxQV~HHcsO8mNSCx!TQwC3xhJT*!!x+;(-=@7kO?$o+-Me+aS8v~B zNi(WxQv@rrJ3z8+#7M_0t+~==hx}+nBUgwdZ_JDOEOFCcODHMo){}DQVie|SD$MKEkFlZoi|cR&Gve=!j1!R zArG+;hcM6o;VJ*Z$r2{+%`6O8`lu^Uclz}#h|cBfMhqcW$-Ub*i84XE$Tw)vY{HZS zK7mvK&L0YY%p?lITvxwD8cvAcYPunZI2+2={12*+grlLiJs14FVbsI%!T#e*(rH+`c$ojpDj$ zc5TTryM45^(XSvI+Jo_CY~r0#s)X^iPe;-~&s4h}(tO<4RxMO7ML7Bicc z#?Vpi9{ZvO2L-((7s?b_6_qqo9Qckfdo@f9#KDZ1n_*F88=U`h_*$xDb4ZdVIHk7I zBSk7==O%M%{V#I6IS>>zEeI-LJ>NozVj_Aj{@hNI;CyshUvszqOrt)DcrxNfF!)&^ z&Z;o+R$%zuV_r)=R<#W>U@E`kv-|B`HA{Xnmvnt|!w6r70bqb7H_}9ea55kV zW>n5GY$^A@fMaghNP1ZIg4yq{-||P_kl*)5p+XYYip(3>aC642ZDS+ z!3JnT16Uwji5!MH1_gHojIbjg5Mkvvt&m(QC+$pyn41FjR`$KMK6Ozeae&8MY z5luj$Sj6Gp<=L>mGVZkKFaZFB;ADrs19I5c2q#Mfa*Q*J{yf^d;}jo%54`D{<<~in z3m!ymkAlC*6i!zrVW&l7`sdBQ`h?v*^SP!_%HpD!qz1ving!8o6OjOD7z=MEigaIu&xw+a zJg^Ncjyv=MR7mCWwA&lo^)sSGlU>f-s`xN!{$75>GAjm>B}+Q-6hV2Q%vU@rruB-=`S1)~L~|*u+-Egbr4cy6a*P+I0T7tMjg3;~Wyc zy_Y4D)E&vfIcCA=$)GdL?&9x6&eYL-fmvn0FxIq0mD}!u-Pf-nH$TUed1T&(z^z>d z%cYf*cMG&BxI5PA0DX2@IM<>cG?3zsw+-?3touv(&qHWC)7_w4ub@m>2I7ov_EAP` zmaU27$x1EN+Y2N7tRqi-IE=q4uT3AbHqs4kpr5z86Q>vlAJjNwZ!Bm?JV@r%f)2nV z)Kg}wI94XJwzDnCKNxUj$`({MRNS|pIzbP90b}RC*Fn`QZ#kV)=UhT zkidDL@!(-haXW^>PD+7L*nZKtR9lf6DWPtgkyUMq#Nx z#Nina$xFfcV53a3M+RxZJd?QAg`)7zJb!=fl{ZT2K#!TqmZH@bU2UVLEHWV>8AtNI z3^8Y#U;|z$L3M12{#0p)4oHE;7VF|EZDQ>JqozCqURgSvdD=YZmwTHT^`M2s7oKHAdiyWEr_k*YALSUuZLh{$cmJNRyTjY1t)tPe_ns5UguP)l-eO6t<0Iv0w7hov~;(;4`I5CO`e22zq3 zAvKXf`F?HLG-O3xFfZbnvECOO$-=ezhqdu-MFExN7Ke6S;C35Ty6M&C=V(`-+?U#^ z9qRZ*1A4!NcRKr9Nfbyd3lRq|`1dA>NM=`^9^Cm_lfNa3vn`6kn2rXDTAwz2qrF}k zB>xK#-wY3jqQtu4G-}2&i`zXi?!C;8c$sR7gh)WdLO>1Ss60&BlxWsqqO1zq;2)T2 z78*QV-3sQS_Qxx)1u#~RmFtk)=~w=)w%&8L8W2UwX^NsE2x@6Ax90E{r)sS&fJ=9f z)uEc|XqKNy_@+kgy~;K={e6(}i^=)9hc?c%4|eEHw>J}*SMxt5jRxk$GLzah?WOYJ zNe2j-qfXe>-xVHLR?yGR!sYrnB6Woli@?KwWJ#g@WDC7F z(DQTeQcyg3=ZAL~B-VDQs!c2*3F!6{dA=KemMIWjr4^NT+rVvGzVBbyhGINr!sNpB zYv;y^iqWUr4dV`u&tClKv9iX~E#+=Qj~TkZHPiD5adu@+5K^lf+2aw861L>f0k31l zLUo*i^LE!7xo2ZLALfOVAF6#~%z5fFkg3@UJZUxC)_)+h<3-@GT8O6sK}ljBz#@o0 z26GMPGp{g<$aO$pyUShPxD_u}gaTY(s;8-?T1)X>2h_m_4|4YFjOOZ!~q=P+&eZ88-#@n1CBpI)yO?L%HO_txnn&(H_N*1{kZrk zO8UCzX4{Jqo{ze$l`R5A{&7lWd$^iYESbG}Utlr6{>Y@OQ%)dXQ{g)lP8un0j8jgL z%$2@HVuv2CaNKVy4{8!?Q&M~C;qawEuj&Z%dU)H_=)XT~4w6Qte<7RO+FMw8gZHkH zcPaU|Not(yR9XELO`1a!se9VNi`7VdGuBxC()#B3bWm$pJ^4CibsKcJB^l!`S|{3< zsPaLA{+cK>rJUjPwNE^P0`?oKs=(G|w>-x#+lt&LmWbda51{o??}~&?2_G4Uw`|b@MiZsj`T~i# zh+!Q4EiXl(?kaPJRhFT3jU~7GNEBNP#42Fg2plYP=mrG+%12N2z4ET;2s3&7TjkyS zv*a$l%zBP(BNF;|3x#AO3Lz6zzmPc4mv9_Ue1g~JQ96p-8YZK&Vd1~5v}c8Q6Hv^& zmQXUygL;+}a`Mw&b1LG}Z*&}#>$}R(4xIYUbEoNn4WY);?R@x<6k1eSXt(p>ZWWoC z_$qU+JG|z`I>F>iD_!Z1%kvht_2RP|j_LL5CR?|K#Fn!SBE5@MVYV4CK`u0FnF{q6 zhZL_GM&0ziy3r;n33PzH=G4fhrzw@l?$v)J6Lk?(MM+QWfKmwVm)FMBP*x{78gGcO z=Br{2+{2Zzwj)1LgA)69u*7;!5uGDL81m9{mo^>ocgn{Om;>z5q316PeOspWho<{Z zm?|jY(D)0J3s$E^ygXYlQI`mE7y8o)?3K1m>wZo<%W9Tl;lA875VWgJCCQgD`EmhO z*R?2ZTEGm}VtB3X@ud(sF$}N3<9DLPY%&`$F(_k61BbwoM70qug<5M#5Tf}^0=sU) zfYmR$V%N`tE{IrqcG@$9kI_~gwMJW~%oD39eX=m#smQZ@OXQzKsExT!#lRWclN&8G zT(@E)YEZAf;O9MXuV{+?4x|4Ozr8?4(Le#-ZayxXhQb#02fdaem!z4xr`U|L) zH>WRK6pdsP#PS}IYlEn%;;nbquSKodBLtf`nI$p~*D<|opW4HIihI&)M~B;L$9K)f z{SH4#(}mj^j60nZBKunyO;~=I@1>u#`gr~(FO)3NiwnEcsce`l!lPG~JG#$ek7^U^ z*@6T7b^+qAwXOM{zX-vB={Oms6n621oQF5LUp%U*Ea*Ld-abC zmX0UdL6*$?nA(zK+8L>WfqafrTjBdS{>Tw-4Pln&rPR}FY^~2+klOZn@1WjSF$l`D z>c02vOVg({ZPtr&2|0#$P|XM&r~Wuc4Nb^Bm1?*oYsY8vFPz-UEpcJ`W+jA*syk$* zRE(RS)L|LPAo`b6Wcx4_7BWD>%febJlF-+o?l(-QpEj7HeZ*9n6EToRQ2N3RWO^QG zy^E}}$~jsTx+Pj~rjO{&fFW2^dWzg$gA#Lo`v)Mq|Rdyj+WI*L;ps`h7vrLBPyBr~I z-b@mq_|DOR0K4$18>9iepIP)$?gKHMG5VV0=9Lu zOvAm^u_GX(stro+ZZK!P)w#QBNIR#n3?OnLkubk?8QPB(kL-j^O+&(WpU#{MjNkw~ zA@zJ^U?*4{tXUlo>SKh&2Fmvo-VAKW>6k{ZSX!mUXVc7wh^*p)(LbfC+kHEl(}&jq`NKr+kT#kOoxKDZ~S!{t*o%MTo5olSD;9 zWEFxDCP2nsW;Q2!L@h$;y`3rhn{)(4*ssn0RhT}E)1L)v{qJzz9^buPx{o~`PS3l` ztUd7Et=fl9dFkZnRtk2<{~2ncaZ{zpNSxmb6<;)Dtf-wxse% zAwOCo3YG9Oj;8fvc+5t@P`vS1|QVU9Z{?36U)AL3>&3 zx+V8sBS^+bto=ZV(!*4O2n<&RqCPV7Duji5Ard9{BsJki!6@2VuWS)*LljPG@;og~ zV+h1#Gh^_6dU=W?mgq1%Ez(2_ejG7rD7Y8?tXnKI_sSPc63A)@z(P(^4+fb*HQJ+>gu;N#zFKW+4~GK^dk0y>)NBm;aHi0QxFU> zmxAb367|K)j0E7P5v9NthYD84(Cx2?52NkOi&%om2UOD^qIWecC);jxG(n>)AC?rO z1MxY+APQ2^Md_Xv2=;)kC}4x7X_PT)rl4_|Xsjj}vGMQ^UN4;tzrj}*P2noop>_;zI274aM`Jgl4XM~HHV9@qqr z$16!%&~ii_4vVRK3T3&ar|h7s$@>vYZ^$Pa>;Q_#?y&uo`v(e5xg;p&`mFfC&R18V z^4jUjaPk5O0J*(Rl4J}Zmcg3=wu`;mELMJBOC`iffSXnahT|z$N>6?-g>0eI5mfhFamKkVxW$xOou=|1861y z2pi(gLN&n(8?bUO0VCrWit$ESNaee2R9G4@lhkTvC9t=5>zP7I9`~mE#*FH593xyd zt`!n+7XWI=2K#xSy!ZaD|D|^J7?x$E9MI~zSKn!t+R<38&Mir;dGo8TxfnZnKRf*6R#H&fMR~7G9MrJ#ey|1+l%k?zbe=AzY&C=1HRZq_3VxDhncM`oL8stvP zH(Jnw*Cbd_E1wGS$-)x&TAF3h?U4!}d|K2DanEsCl4kF!$9yu2O;VIqSl+Uc+1*D~ zr^fWE9-HdNfQ@lK&7=x+wp4a%-G{5Me0?bV>Obe4)OC)je;rj*`rVT$aYEpTDmuvh zxotAzDkLiiw_y*PN_Y3gFDRZds^c_WmnijsuLnYt*IWRR8}duD{Qkny;c*i}!u1Nc z#4OO}ZtkC+j7H2{iJBi($7y6dLJ}@kT~aq$vnzC9K=ipVBe#+E%npw(^WC>+a^i%U z7~>k_-Oya@$#lbSbHHk+l~8t@co)&H+@_q=P|d;JDqj>8E}LwYjrmyQ?C9)57Lx9h z?pM44F1Oq4SUkrUCK-n;3y$sl{GNWu?(tpyS+hqOf=1^{dqtCmRj=lyZUbd(SX@ zVjaG~x09c-_WP@??V{fQ_d#ZG8XY*pV14`P)%@?ySM#*O8fj1f3>tf>*tRbZtkq3@ zzZ)&m{Q28k?#hf><9&|TyY%r(~h7Ibd=t?}9>CXJ5N zk?mR|ipd5%=w#=G?vw&XA^VbnXOVpA_shC2SG#ME&-J-3*Go){t#F3g_w8rS_Me*r z)91IC?$4vIOS6S`TmHlh6rWa;s#co%4TAOzRA!UWK|K~M0KH=Ca_RUokHws5UF+69 zSmQ7)R&v*9(&O~yF&Zy$j@9Ouq9DoiRhEe)0LB-{oW~|!7#P#YA&UlPGoZTI zh@uCi{6`=GO<@QlTTL}sTymT))GACp*+))9%IRU&S=@LO@Zysls!O@cL}d9TDL;w^ z>7@07d)NJt{XjY@`c#Z!SvBgAWQ?8)bW_d}VrFbVV+0!S}niPazpnBBTaWY|>F zDT?a)QnB{n_oRsHl(sYroDGLJyj!NDJe9O}?`40#7@^&a(gM5~KMkskc+YnjUf6qry^kwv$+s0+2>cfhC1LNfzt4_AZtni-=^!) z%3l=8dv-tVqOG!&*jAYeX#8eDZmoB*uYbZDU!rUMLYBsWGDkz5Q&tn>g`*-;YaJjQ zqGACbjx?ur^2ZUSQqgG#mXk${g#M_|vmxjgs;ph$aMOWxHP~&ZUx9>otx;laz;^v3 zQOeD%^pghN4#7w=bVS1EIwch*OWPexPoEz-9t!h;h}iq~F1fHpC8cW#?Z9m>kdw zSPp?48e|z?rUR9-*)P{O?v=7l@z+YR0_MhcarV%^VVTu64 zw}h>!&!Y_f7V#@|z4ygQpQJZu z__^gh#nS?O=}9=)ts5bRK>6+m4h8C20{5mv-0XoruB8QX zRMJlj3T4#NE0c-B96__vRbYLk=g@6HenMKW8E*Z)=Xr`wWWrwGi^eO$_-d|fpW`R`@Sx77s+p+Kv(0l1^r~CJOr)c0E$0r< z@zW}#-&W1AI}+rip^0K$p|?{o>!x$P#lZbxdZwonlRQ25{sy{V3%WF}L$$fTJWk15 z*;EY>h-D>s82xm0R*O3taLPhG~dS{a}ERY84TMDuE`z>t?Z zTd})TDKtPbPLeQx zGR=>B#q*&KwoJ)NfjOaYm6D8`j5ZcVN~gVOcawF#DBnE=Drs%|Kxqh+<{Yf+G1JHR z;=@vII?g{f^kl{U6Rc_X(a8(k!N>)~P*_~h3+^_g|1QS|va0q_4~eyU2b*))KQn&i z&-3GXiCeC~&LDwouxDPG=THCL^H!;gOqS^W<$2_c6I2MPbExB;(WR>YN6!o0{qels zJ&+=}tjgzny^ni)9qF36=N?Qr5z)ofd2WTxhQi_l-fXF1B-X4Rbpt`UsG>l z+(Wvp-S9#k_Gx*U8O8iRi6*woPl#rT>98tuAYsZuX-Ut>+?=Bffx1{%5KLVu#9-0b z-cV=DoL=EMP4dmCpQ{S8XPXKEX_POIpLDLC$6zsNw!nTM$iD%AKbjhn!c6rG`^Z1w z111)Kwa5DVc+A*hn{A7ewYZ{xzMlwmUA^wAO?oPSvW4G3P@ue@4eFgpberK%RdzHT z(Q>5q%0P@*U~s;_JtmOCp;=b8m3I1*teEjk$)R}Qyq><~Ybh6CoD1KWnnJ}nvs{Uj zBq~QqW;n5nTgONFD^tKpl+z}aabR(cILol(CNzN zvTv6NdU7TM_HW#49)$SsxVO3dpSWkIWG7X+&56@ObEKl~HHGHk>FVQ9Q+vy+!hv1D zd{0$gAFp9LPF@maT+9N`{SWGyUiPEp#a((|ewp%rN2>&ZGDhYa}AL z;vb!n?H~K6z5wAJ@hGWEyd&m1B>br&U%s46HnWSPNn5zRE)A|ZE|@YHTUJLKY}!QJ zROjoiRkM_E2D^GK-B#__@4@}$e>}N<4d*|tT2c2=si2WQGdB=m${LVVB+oH8?1fTw zp*8e{i08mu=JhY)gN=UwQ`yu=3y8;gO=)#Ax+J+MdA=mjT7QaCIQ?1wOFuxrd5R}nVQo6wQd3tNz(1SQ1YZ=(H%^m8|H#Av%kj zK}=quY15*wRS}tPGw=T-y~n`_DMbBG3Me&HX4I-vH+!w*>S$`H#lhxQ0TbW?`blK8gtjVm!aM(nUIP2SMDOp&|4#JImfckb?)Ud- zMw|YPd3YYb|CIkH=2@q_sYNL7{U_$tJzL2RF`3ew2G0hxP(y`nd%Z8JKI3K`hdjcfx<$QDrKp8bZdeq zs)>`Pe(;Z&EkyT2G8Q=MBXj=rt7}AVpo-ZUv(Aau&8CIm5KG0-kJYh`dsisl|6_Hg zgxlhAx2^sHzm>zaxUN?6W5HVQHUknyo8OT%#xZ4+-?5vak5zwN3qMdt^|0peH+j=a zYBd$PA)HbXbyF;;Z(?9cnX4RUO!#X0zV^~dGN7z6NBqT=2$&xnT7j4LSw9d=TCv8w zdfqo^5YSl==f6g?@Lobyvt8$vQ}he>I7(=i=$#9hRZnBC-0N6}Xh`~4Cdw3Ex10m% zQ-psea8VfeqTH+UfQPP&pUU|7wNE#QnK9s4{72(bnuR=FvqO<)Yl1Vo(TLh(iLA99 z=*7ArZ)Qq3L-AKymsU}D!~`qJ%lPbt10o4t>q^ibRaa>e!E}>t*d66lU@nqVs~=FJ zdy2Jjxp&VZ$@VyI>lRKkJ%O5lc#tUYjR& z$xC9$av=UfUX14%5s9jnO;MFAz0Ux7iC8JW#g{YdQ7%Y)YRi-L9yMT@(_LDMMBdV1 zHCu>J?qITjXsW^#wpjOu5!>iZj#@Lz+B1x-t`{w6CVhzj9=2vNKTxGFcIX)b)vcsv zjU-m{B<^IPxE;G)sV5SlK!t6^V3wc*eF3KvE9%ddz#-j$w0>%#_ZA~)UN!!Hj4*9^ zTk<%6zN8J$U-}b~b$O$C(YZdT^;y&~y_WzS=~95W3P`beLJD!$$Jznp+F#)iP+e52 zFuU(j?bJKpE`@zUgz6kQ(p1@_)B{c9hLgH!X-d-|TwTUMBXq9|M*}+9yAEmdj7#~? z`QVNVV^7NzC}V4oNeC~8+|qw&8)U(9U^^DCsGVa=68!^U9PClDtAczaweo;P1y>Np zaAci7=0T$pI#iC_0I|wSE-+baLSKC<-VxSunuS=)+g5FK#bkRdjdC%g0J^kF6P^*xk zpP?nw9OTSYs}RZg%Ep+V8GqYUq-Q4Os6mWl%Z|>_5=i@b$MioJeA0dZ5O(5J26 zIxU()G{5@yC4Crmx8;2B?>PG`tE-%n0@q+|IWN^KJ4=Rc!UQ6^XhVN4*mCv002!3F zWDX@nQueO!_4bMM{{c8!!!T<*5bMj92!~I2+0j&A{C0 zKnSvylrByiY@ml;UE7ROd@k@g1q47?%b&ym9d^Q^d*>euo`!cZaSjWXk&6o1*I@iwmXk}3|7%DF z2s&DLi)~g+C}mJ>h!h}8gF}bwM^!7E(Mo+&YskcbSI6n<7jAv#fW!7dXV%JllCJy) zk*og_Ej*LRnJ^=6Mticbr{D8nha&Z5oc+Da@SaTN_-KM(-#;n9)=h(CeR>Iba=Ae_ zpz3`G&$XR#fBXtIpp!@at0l{RpZsaS0Vx%Jm_7zVwgnb5&MqR(UdP{cI;?KOl6Y4& zPdNZ$sn&H53A4A@kMajXmZW^nHtmh{f|oTZ*W@EpsFYN(H{P!Ao3DVJEg!pU z)z6yWn}1#&kNon5&t=e%2!wYjK@LX8GG14r{0_r6lbpcRPA?o&WU0q7ilW7$JEOY> z673-ynUW`l6afD0ftpkxVLRv*k%5K>L9|RDn$y_`?a${&eC|<-;7K&qzo`pm;3WcB z5Q;+FLDvF8m1UuX57Db`Kw#Ym5(Y!;sbQT1j>g@D+tJpVRrd*iR2V2`rGT!fUj{_1 zITUI|0?yh|CCv&A2|(1MLK|MY8+0iQ_~~WFZW#{p`3tC1njwP!(FDn*(Y~~JPc>?N zadk`ESASY|t$vjs#XG^mTsw8+>RAPZa!XoU z6osRIIo)1%iAea8!t?A3_iZb}p8Q+lR@E`Cm+{S`;|{KZ!671s%cp#>0ive~aa3JD z0Sh+1d1%Q(aFcaqJdue%zBQtZd}Sp4!}tzvwgp7#5mi63;u!=hIAJf5WM%OdpCY^9 z7GjRsO;g~LieW!-Yp+CY;cPwgM}cLyR#@=GKTwCM@B?)}5&b_<$5L-fs7rxW=5zb8 zq=?w*K-+)JCyw2_C4XgLSmxUX{o5(BmpeLY0l>H}czBKjffUn_a@U?9X@>$^p=cz5 zHXz;%Sg(dCy3U!TF3i7J!8po!#4HiM|9>(a37$PFB@uIcr~QB)46!=9Z1sSo3-^RB z9<4d_*d-z9vdTO+`)WeM&s@5Z)lM@bV*Q;-_OxG|nq3I@KT78}Ed{QeXogCojrVV* z^OMgXBg_y3rfG74AQYjKoJ8vrL!?bY1ZIZ`#w3bQb!v!-uj}_UUCUMbRX=DC{j@1B z@t66L3YF(6(l4UjIkuRGy;?}ng}Yf74`x(k?fV1885x6h2qH;toL(4}@v2ZPP<~E>u=F@gsuYi+F5D~xQ&;qZi#&9Q!bL+t zpsjffk%($`3_jQ}UunV`8;QSFhHTNFBQ_oN_e?a$e(#cP2iY9EXmvAQ{XYKJuQV}Z zJ{w&8wq}njh|%m=FAmp;rBE^Ix|bKJcIkHJkoxAF!?Sn(=buo?hS=yOYZ<;16kCp0 zZ17M5B~nPklByx0T%q9+U(%w#g3-je$Ogc~1BS+3P03Jw=#GJdEWN11F!LTbzYwb> zAg|bln1sOT{%?>DF&36ueVn`X2kDODlD0g?;^>4(>3|40!(1#_113X|WL1;exS{6^(KwRiYkmseDv^dh zT{b_5gkCll-rCE&A`6C4fvwUPJ7+Y_-2XZhC%&xT^TbfDlzShFt0@k`GZg|^eytM+ z_1CwP+)DfZ9PD)B5Qz9?D9hT8sG^Z@4KER_``lGrdO`cxmK}^?+vyt%JJ>>+v4)FmvVcnyuM#PnLQxHI9~hR zkoexXe-dn5+Skepp@4E;LzPgN z4Gs2e_kCOA{gq(bbGqH}esJ~E#;7b@xtMdI=?F8m#{7gCPZKXe$zHS-MEUvtCfx(D zcdhyignY<}Rz09GUr_B8)$MF-b!x1-WZ{$2wkEZ~&&K`aPytJN?vY-3X;9CJh5UKd$t|3y&_9R&GMpFR41Z6LcR0&;=Wvmat2i%L$b_}heKOmD8{(7Y2qQ(lYU|Z!@kgUlF6x@r$K2{@U};pyuDL*Y)GAV=y|+M76wnojtN#m_x6hB+5;&&rv7&xoQMzxp4#a4Uo*9^8pjhx95RN2CA-R+ zuuC`-G|oP&neRPbFO!=&++?Pu(q9T=q!NG*;a!n(PYt$BxQReXgFn0YgnQa1)SS$P zO3vJUKqD!UQ*?Pv>6^oM3~P`%Ooqw~4=V$Flvc=y?I*_Gn_zQi%*w?3y`e~$b; zUElA|J%65uU425gKJPoWe?{PgtL_TT%sKmU*7&N?j0ZEfR2 zcStu%cXx+?lyv7H9m6ny0wNtsBP~cMDJ|V4AtETM)Waf-g{@Q{aQDQ1{iW!iP70}*!aWCgyLC3O!lJq=xi%c z{NI0giCIc&aG>nNo}=83qhg7Nsa;iL=G$_=M=WgmNh;fQZIlNt3FvLC83tk&Md#df(#C30MejR!qm(vJ8i0Vsw+BZc5`4 z;AIttUyR6G_ZHicCP?i!VY!;acE3Vz(;P{7M51&m8@}Fb=|Pg7J7fj#Kl7{-mv;>! z9j6D`Y?6v%J>`_ZHEPmjWVN_IJRC|^nXmhV4HQOjE+_NmLhePo zcmOB7UeNYwvE;=w%>^$ktn+ID2mI*_O<1-RgDYp=DC%cM$B~BkWd(V|EpINEV|S#D zVewK4^k&cu^mT0|x|qXA2T zIN6&9gB*rV`b)*aiRdAVq3;BDTeH?kGKYMzpr!ozMFDlzbUd6Q@cr>6n4MeQ)@R5g zyX9wMwL3155@}nu$-)KGam^;t3j72)JIz$tuo}SSmeOVr~km23uzw$;Jv^E z%N^OsY}qI;=aINE5$d4|i>hKNppbLstnSa>G)*Ovfo=sRkRzy&`v_*x^O*pSp8-LH z>8rW5(CLm_jBPm3y}%~9S@TbiFoo`(YjZb{nR8}pGTN3lx9ncy@Uc-O)=`htG|B;v zTG$UOZR?@CbV$Dwi1AY_m zB0Ms{t2>u=LQT=jD;FP^wq{lqIm@1^t&}qq_pOK;181sr`$NK3`A?>7j9+q_0x9mT z-F1DW6)$+RyS=#VP7k)Su`34_Ebb#uAOyIQQ{~SR@;Fo?Hi0PO!2Ottx}HJJG=|k0 ztSzxLLG;Mk;g2$&qmPQvO>@vEl{}_lnj}Z{$$E5GA2$Y!;?rI%lhbPLh_1ws$gk*A zM>4#=XZo7Lt|*8%&qSvn*D(2d7K_kO7*>R+6Vkz}H0nKu1#~wXb$UL&uZx75K`%Dmo%1(_Zu3ks)YR{ zUV^RyK0`5z#;wm-ev{`zJZ6a5x$c% zg8Y$d3d0)tGsDgRU-ll>b^=_2PUi3d{jqfU5YpV^FHqi9iN5znJ zu=II|*+tyGP4NkY{0aKGmRU>8ii`(ya#W4t+k#4Wp@4VSg;zF*kldC~+{GnR>+ zF^u=B(`^fTxZ^Ba7PAItlqEkETL`z>6%sX@6XN=>(B*V^i*Ar3;xgDQ4s9U?mYu6* z6fhw%33v_1)Y_`Gt6AJq%jTZY%r=mOZ#|ODZ`YDP?Bj9H>ce9Fc}Ri<=*R6~7J*-Z zBWM*3U#^~_4{XqU=oaYS6L?2T6`vH_tNOL9a46$|8J1ZU>Z^_zAK-%gix5UgIQ`RR zURP=6v3D9P-gPPp?sgvQYm`>KFk-2?}~1I(P$WIB+rTD~;vY zQM%Dq5sj5z<{q?_w&m&Wv~I%_@cOv?MSNd#pW6wG{Sb>np|=7(|KKH!B{G82SR09g zuQV37O9o0~QS85?vAq#c8k-D8S}0)|yri*F6Ti{e#C87Bpn2zz2K^~&-lPU1M=CO5 zj@=xe5xMue7x+pqt+KT1!9JhZO~VKiA%e=$Op43oY-N_=;f=+2=RRNe-W35Hx+mi9 z?j1gBb{VJ=KE92?J~i?Dl2HfINshC1_hjkJD~sb)g=Lvp-1K zzqiI1y9;_3<|#I#OeqrNk?-) zVyvJcv%^coXsfctdjGR#@t~>khhCCN1EH6!uqH~wY?`@4Vy-Q2f)n|C3t(koz+KFV zvBePSQZz`-^v4uXnZiTid2&ygW`A$h^Vdaf;$;im%@>nv{wHx9diwh=w<(X}-1Qd4 zh#w+w-9tfi$B&!XTsR>cGxQ+F6$$uQe8;89XO8kRa~VKtLYY4y9Kt3HN$a!-_QKNm+LuRh(fB6lgA z%(doFTrtr10&l*7(%Boo(OKWx+sg`FfZf2%OmSOFEm|`U5)KTm3Yy zTOh>mIl3zXnE+d_hMm8nvqAoNk5Ma-m+rys z1()4xb20_}ecG}n=C9J0P9LA4(l4cie_TM<${2}Gi(v28;(bzT4DWrn5?jw|A=O+; zZ>YLlJ|Sk1Zj3=UYbQPPL_O(6S%z~Ag^*d;bQq|gbB+jQ!(X_Ok$6F0+A0Q5HaKCcfU1lyz<1L>)Mf4&CQy#|p$MfbL5zNX`;NW#QURF6zM%E*wzPr#I__knsXMOUdYXOpX5JOeS zc!QtPf{spm)fuR}4`*S#c+v4?ZGUVdG<;cu%1_tC$O=yie)+LT$B3B;p?-&B(p(5r zr%lOs6y^hisEbOPm~hAjqNBjs+8WPH+q&4kRi6T_d2C5VfJ+PUd0y-uC589tY;>~k z=w<3sVQxoj1Oj&Ag4ucl#k8}6zhl}cVo9mhSL`MyPS_Le&9GUXS=sLn_c~5Pa++wO zfq|OJhz|fsK=vk@9UhO^GYDQ_=UMc9QE{cI<@DN|_t33BWKUPDJ<>TWYP`iFU)swvA-$xP?6u&7C5cH)GFuXv=QOd=ze3Rqk+R-R7IiIb(&S*$C$vg&dao1m1ro2w8yuH_lqkK`a zxDfK;-X1%=>Ofa*^UEj)@kw2zV(frch@!FVbODv27tzzFzC)xV(q-v%J)sJJ`*Zb?$MATHqNHV>yM!Rt!l0Jx)7ZD* zs10UC(WmVYyG5JeR*VqD00Eauap02}=~grU6y{E zyJUX-NA9vB|F_(w6c;pi>0Znf@2Pk*xf#fy@bq3WeVZ?F=6y5!TBWom&7L7cX)kwA z_QKgCCw)meMWRz&1`r1$vq)E?w)JVZ#}`zK{r1PGwk>>l;47>3mos^T?k>kJXZqB! zb&74QcR>4e^zAKoBw8b<*p;#mnZgF3fPj3?fu~+n7JW+hdXz$0Ws}PW%%(~!*LE!r zSPG^dL>2l;dnj@|t3uCaU$whw_8^ExRf@TFkA&T&Cfzb@ z)G0G728~skE`Nzta#gkW{~oK<)4YsTlAdeDxJBQF%WtX#ZZL=Qgh7tUY5CJ!t zdM$b%Xspsb#>9XkTlY?%^X+(*{D#+bGR`>=g`8yf&Y1WDnLZK(9scr02R^*<8f)in zn6iX?d&lVG4tQ_DCq}nh;o;e9R8z93%hf;B9I&c+wVxxq_+j#I0lAP$3&XUoofJr; zjZ|<>p)$tj=vHjMCGt|cZI zA-n!MJVu-P4#G~rJ0jqGuA*5uGT|^y>$R@15<;=)>%I*$yW5AlEY|K3HpG2G;V)(O zin*Uf(`J=z@pMn;W`)s{qrfQJ%JVnc0N>|;uCG+Hl6yx?5P(Q-9ZV32*#KTU=D+FK zQ5?^XqS9Qm4Ak$3bV{*iR61nba+s(CJQ|s7R3**P@CZm zy%!37Sd(x#o&O^=gQK=Ek5nnS4OfgkQ-MURNtUy64T1J+SuRd z(J2z#=URJJ-=%-eSgt&7XITvl^jlzHS?cX~NG;Cxk75@!q6i#dhI@d5C6z5t1mRB1 zMDX<|%?_lDFp+_VEXgVM-4co`SL;gC*4vlE?!uteV3thIwlBNCPo6}oeV>&fnWPTR zWw7N{spUxYl3_&Nqbc$N)u?8it5>~D>dSxl(%0S*H-;nK7J1YMv%&ULEWsBg^t5)YXrZHF9glM^ae_-hKCFqh`_;OPJdl%)rzY0qLa zY*t=9-~rbrwdbhdr~ZzB_nQA20sC}A5pcfXAnKzkfTmof=*>?zR;7)=Bee{!54@eV z@hZ4Yc7%#PD9@C+;HnbQ^J4{)(4{qFTI;glHVZB^d>mvZzXRryZ+#db7+M|5t0iAO z{!m^qI{LPmshce>!+ImhgWc1K;#u7tW%4(qvK?m@YE@8hQp@tf!h0cpxtbJua+J{4 zA)_&|@Aliaw6E+p-Sk`b+ll9|)9s7;E&IjNC55wzk&;x7fEA6JpIVs6GgP(U zxK4F}M>=wv2%erR=Ahovj^`2pv;%in%cVOlKGa9 z&Yg4hoq?0w6+u-V(BquuZsU-d1YcC_mE-aX-;LSAH(`M5+omHk_1Z0AESH&G;sS}Z zr|N=WDdz+}a?Y&~a8l!dIJtTi!NG!@@$Q8*pP9-b%s}Ug!8hqOd`rrZ=A)ntZpqtR zVFkRLakFQ(vVy!ffwX?;xEzv({?cUBExi3Sm>V2Rqtw}CpX-8q4e&_xCJ9}|P&?TT zobgN&mV4DNdPi}3Z(Tt5Go1F`8aTz;ID2t1^t=wMX__as)Ou`1YDi;iQs{%Cw&C>- z5MW8@-rM(U%_(JlMq(-~R3;!L8OUpUt^gMF~7z#2{x6{ z*eZAKh6pJP6`hcCUDDoBs!Q6NEkK|y%#0U)r>Gj2?<0yFI_|4dzF{~3^&I}3v8kGg zL%_Taf~pXRudHl**b9)zB#K+ro zL;%7fH~yF&d$#{H-}{&q`A`<78b%B#7|C1nheAsnCA-{&$dzvePuf6Zkw#hE@D z4}n?wRQ4E zHokb&#Q5334kE*z(OVb{cy?|qg}6@7I4f}|=+#k*TBAinM2_pn{A7Ll6y}KxtZRoC(vB)0PD5x=8i*e=iy8~8f;&Y}3+mvQq?iUf zxK8c{splWo&&4cZB-Jz)n)?=1BYcRVK_f6!hd)WTJU79$syg(UnIm8-;v?ZJY_72x3VpCc`^11BR7Lr0Ob$YlMdP9`(!m%j zElq^(8uYWyGTa^EPExdk5T)q$FkwaZjDDI^nCkxms@{?W0kl#NDVC zHJlr_tzNo(FKSxls)b5AuGv0nmm}$KC@B<-tvF-RnZc?pdNvky-KE@K10+!lW^bc^ zje(aTq(&s{z)J^9D?6GyBS(sZ<63zr%iYydXpvKUo03&gew;}8lM(eF={vkeNJgO~jg zeSM$9VeyC!C*GIOdN`QDxBBV6(S4CubQrG-(R~=7yZa-1X5^eDj!yHR@om@ftzf3n z=u-yi2JwaYsGpK^wd%c~dy!Y+GjaC85?7WiSRl|%c7T=rSP{^s>~i98y-S&N8WUT% zT)3@(F+_EW@IxR64lb}FGT0Xo2RD<9flm`uEL;63Nq;ogYV=mvlQ&?Mbl* zt2nJf9~T(}zA)SEALcc6a_8f#MWYHqt0F$qFXBr<@D@QFf_K|k3jsY>I5^Nrdr)6t zBc8iC$X~?=sgizUQb7=5GB8UAUwyEli2N9n1INEEupj)OfAwIt>wOAG+W|vW;%p?U zR!kbfgu890mqS=M4Y0#5>5PM%3~+=;{I>6!D856MF=OA@Ha zy)Ag^FLa`F6Z(huCQM6$nbi{zug#xgly@#XDZZ!C7Ccl?P233EIE4RF-)L&T`Jxqz{hCDJL#|Dt z-Vc7;UW$Gw6h%SBJ1oAlW9Cgr26__annmQYR@>m(W1_wa=ZRZYDlYE zT1ck5gD^M`*qvF<4v5TCy72pphW4+UyGr_z-!g0EN!Nb85m#P0wNW2;gty%c!|m#T z-&+v-dW+GiO9;@~Kraw_)@@uS4<;i+3orNJhrioC4KKHz^0Z}hZI+M^cQg;%vy*P! zG0~Nchlv8qwg6=vD-l1XL_-4H+UsvsGKgY|88L>wmG)9^%g+dP9hQx4jPyv@zumHh zyPm+*B9RWh?^u@ZA%ff(o>RS<#(@qp1rWu{Cz1^i)Ys0a;k9kcX+y%s3&)hbZm~u7 zex7G^k~X;rm@I!lx`FG{>ql7MPP2tWP=EXj6c$DOgWJx7jn|8=Y zmf=|Ai5wLND~a0J5vsZdNu+wMXh;pkeyKXJ&uC`eb6f1ypxj#Z6N6>iLbVzb34@Yy zldc7&{W2DKm}kqWa)-|8YKyR;urDj>?>#yqwd%TIQ1-ci%Y?amkUZ*RS7R9rWeJ9a zQ3c~lt#0NnRq=^qy;EbgfqqYDd@teNk%X2SmiJ3y?i@2i0)nHd8eavQ<4wcRV%4B# z#n_q1TyNNsYVM<1yu`ckA&?;3h*dn#NW-Tz>{MFlk~PCE9}*reGPMG_1iRPo6d(je zUUZr+Z%xmMU+(q)vW}>R!WaOMJpOjC|L=FScluR({r{(%+y7r~^A7`y2Z#4%d;jl` zK)?nN{ju%;C&|lixj4A^IJh~vOgII(xw!?|UERiR^n>d0j zOu!b9e?9c&X{>j-SuJfq=BzFj&MwZZ|JHd0P&*Ex=M;Qv$E94rH+HyOk$a%@jUC_X zW;6MJRW1cpK2OL^pJ)jkPY>V#R#%i`Lf^^n1^?%AT_C_a7Oa-`j`#jB+SvsNaryDF z5Kx;xe`oWh*l%ryToG$f@r!K!uXXc6b#px^ja)bO-d<|_*4wKi4z}?ZdHbKry`0uw`zhn8q5uGWWLGDkOkb>~KU?bT z>fiu`xc`M6|1`nTUU|zpyZ+XW|J_SnRyEgH^B@c|0Pv0h0I<07Qc_rgJ|I*SqT-3p$% z@iR^T+tZhRT-pCL-mk9Ux`)5W?w_FivhQu^+Ez(N0swAO0|4e%3I%-hGmZYM*7wIA zU!LalZI|?=L;t2rx;hS9p(FE;rt$lx`aaGGY$WJ{MkF+0ot=#ySRW^q5r3W zKo<6Yxft$$H*;Ld{dO_DIy+Z!{35e|g7V9@+61pPyZ#ygkP`<0m|iK9KF*(M^q+g_ zAD*`d{m1H`nt!`1Dg|%;B7gsL!IuTm97ji`4(%??p*{1}S^1XC&$RV#s^G^{#XnW= z)md5P_Ahexzt(-(!hL(L=GCgOQ2CiA|7|1mS7rQ9P2AlpWt@=ti;Vs$+Ao`y)ypY+g<JJb5f7{6YReAg-8v)u=0HF7RuLIEV0f0mVSm;mx E16fGLQvd(} literal 0 HcmV?d00001 diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.json similarity index 91% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.json index 9235c24..f5b99ed 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-architecture-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-architecture-runtime-manager", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Какие компоненты участвуют в RuntimeManager?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "### Компоненты, участвующие в RuntimeManager\n\n#### Подтвержденные связи\n1. **RuntimeManager**\n - Role: Pipeline Stage\n - Responsibilities:\n - Manager responsibilities\n - Orchestration of role-like calls\n - State attribute reading/writing\n - Participation in dataflow slices\n\n2. **ControlPlaneService**\n - Role: Pipeline Stage\n - Responsibilities:\n - Service responsibilities\n - State attribute reading/writing\n - Participation in dataflow slices\n\n3. **UvicornThreadRunner**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n4. **HttpControlChannel**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n5. **WorkflowPersistence**\n - Role: Pipeline Stage\n - Responsibilities:\n - Orchestration of role-like calls\n - State attribute reading/writing\n - Participation in dataflow slices\n\n6. **InMemoryTaskQueue**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n7. **ConfigFileLoader**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n8. **TraceContextStore**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n9. **WorkerSupervisor**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n### Ограничения найденного контекста\n- Все перечисленные компоненты являются участниками данных потоков выполнения (dataflow slices).\n- Каждый компонент выполняет операции чтения и записи состояния атрибутов.\n- Некоторые из них выполняют дополнительные обязанности, такие как участие в оркестрации или инициировании ролей.\n\nТаким образом, участники RuntimeManager включают перечисленные выше компоненты.", + "llm_answer": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_async** (src/app_runtime/control/service.py:14-47)\n- **RuntimeManager.start** (src/app_runtime/core/runtime.py:32-59)\n- **ControlPlaneService.start** (src/app_runtime/control/service.py:14-20)\n- **ControlPlaneService.stop** (src/app_runtime/control/service.py:14-25)\n- **ControlPlaneService._stop_async** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.add_config_file** (src/app_runtime/core/runtime.py:32-52)\n- **ControlPlaneService.register_channel** (src/app_runtime/control/service.py:14-17)\n\nСвязи между компонентами:\n\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService._start_async**\n- **RuntimeManager.__init__ dataflow_slice RuntimeManager.start**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService.start**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService.stop**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService._stop_async**\n- **RuntimeManager.__init__ dataflow_slice RuntimeManager.add_config_file**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService.register_channel**\n- **RuntimeManager.__init__ dataflow_slice RuntimeManager._register_core_services**\n\nОтветственность подсистемы заключается в управлении жизненным циклом приложения, загрузке конфигурационных файлов и регистрации каналов управления через ControlPlaneService.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -120,12 +120,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1306,6 +1310,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1346,6 +1355,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 59, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.start", "metadata": { "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", "edge_type": "dataflow_slice", @@ -1386,6 +1400,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1426,6 +1445,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1466,6 +1490,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1506,6 +1535,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1546,6 +1580,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1586,6 +1625,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 127, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager._register_core_services", "metadata": { "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", "edge_type": "dataflow_slice", @@ -1625,37 +1669,115 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/core/runtime.py", + "title": "RuntimeManager", + "symbol": "RuntimeManager", + "role": "pipeline_stage", + "confidence": 0.67, + "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + }, + { + "path": "src/app_runtime/queue/in_memory.py", + "title": "InMemoryTaskQueue", + "symbol": "InMemoryTaskQueue", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)" + }, + { + "path": "src/app_runtime/config/file_loader.py", + "title": "ConfigFileLoader", + "symbol": "ConfigFileLoader", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)" + }, + { + "path": "src/app_runtime/tracing/store.py", + "title": "TraceContextStore", + "symbol": "TraceContextStore", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/workers/supervisor.py", + "title": "WorkerSupervisor", + "symbol": "WorkerSupervisor", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1683,6 +1805,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1706,6 +1835,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3025,11 +3188,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 36, - "C3_ENTRYPOINTS": 15, - "C2_DEPENDENCY_GRAPH": 59, - "C1_SYMBOL_CATALOG": 27, - "C0_SOURCE_CHUNKS": 17 + "C4_SEMANTIC_ROLES": 43, + "C3_ENTRYPOINTS": 25, + "C2_DEPENDENCY_GRAPH": 64, + "C1_SYMBOL_CATALOG": 34, + "C0_SOURCE_CHUNKS": 27 } } }, @@ -3045,6 +3208,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3059,7 +3225,7 @@ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -3112,8 +3278,42 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 196, + "pre_evidence_gate": 1, + "llm": 9911, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -4358,6 +4558,158 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "token_usage": { + "prompt_name": "code_qa_architecture_answer", + "tokens_in_estimate": 4061 + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 196 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 43, + "C3_ENTRYPOINTS": 25, + "C2_DEPENDENCY_GRAPH": 64, + "C1_SYMBOL_CATALOG": 34, + "C0_SOURCE_CHUNKS": 27 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 9911 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.md new file mode 100644 index 0000000..d6453a8 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-architecture-runtime-manager.md @@ -0,0 +1,305 @@ +# plba-v3-architecture-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Какие компоненты участвуют в RuntimeManager? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_async** (src/app_runtime/control/service.py:14-47)\n- **RuntimeManager.start** (src/app_runtime/core/runtime.py:32-59)\n- **ControlPlaneService.start** (src/app_runtime/control/service.py:14-20)\n- **ControlPlaneService.stop** (src/app_runtime/control/service.py:14-25)\n- **ControlPlaneService._stop_async** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.add_config_file** (src/app_runtime/core/runtime.py:32-52)\n- **ControlPlaneService.register_channel** (src/app_runtime/control/service.py:14-17)\n\nСвязи между компонентами:\n\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService._start_async**\n- **RuntimeManager.__init__ dataflow_slice RuntimeManager.start**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService.start**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService.stop**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService._stop_async**\n- **RuntimeManager.__init__ dataflow_slice RuntimeManager.add_config_file**\n- **ControlPlaneService.__init__ dataflow_slice ControlPlaneService.register_channel**\n- **RuntimeManager.__init__ dataflow_slice RuntimeManager._register_core_services**\n\nОтветственность подсистемы заключается в управлении жизненным циклом приложения, загрузке конфигурационных файлов и регистрации каналов управления через ControlPlaneService.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 196 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 43, + "C3_ENTRYPOINTS": 25, + "C2_DEPENDENCY_GRAPH": 64, + "C1_SYMBOL_CATALOG": 34, + "C0_SOURCE_CHUNKS": 27 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 9911 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Какие компоненты участвуют в RuntimeManager?", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 12, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** (src/app_runtime/core/runtime.py:18-179)\n- **ControlPlaneService.__init__** (src/app_runtime/control/service.py:14-51)\n- **RuntimeManager.__init__** (src/app_runtime/core/runtime.py:32-127)\n- **ControlPlaneService._start_asyn" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 196, + "pre_evidence_gate": 1, + "llm": 9911, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.json similarity index 89% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.json index df03e18..404d2b8 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-explain-local-http-channel", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-explain-local-http-channel", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` в файле `src/app_runtime/control/http_channel.py` реализует механизм управления HTTP-каналом для взаимодействия с внешними сервисами или компонентами.\n\n**Ключевые шаги его реализации:**\n1. Инициализация класса:\n - При создании экземпляра устанавливается таймаут (`_timeout`), запускается сервер через объект `UvicornThreadRunner`, создается фабрика приложений `HttpControlAppFactory`.\n \n2. Запуск канала:\n - Метод `start` инициализирует набор действий (`actions`) и создает приложение для работы с ними. Затем запускает сервер через ранее созданный объект `UvicornThreadRunner`.\n \n3. Остановка канала:\n - Метод `stop` останавливает запущенный сервер.\n\nОпорные файлы:\n- `src/app_runtime/control/http_channel.py`: определение и реализация класса `HttpControlChannel`.", + "llm_answer": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с переданным набором действий (ControlActionSet), а метод stop останавливает его. Свойство port возвращает текущий порт runner.\n\nВнутри класса определены два обработчика: _health_response проверяет здоровье канала, возвращая статус \"unhealthy\" если действия не установлены; \n_action_response предположительно обрабатывает запросы на выполнение действий, но его реализация в данном фрагменте не показана.", "answer_mode": "answered", "path_scope": [ "src/app_runtime/control/http_channel.py" @@ -151,12 +151,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "HttpControlChannel", "alternatives": [ - "HttpControlChannel" + "ControlChannel", + "ControlActionSet", + "JSONResponse", + "HttpControlAppFactory", + "UvicornThreadRunner" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -738,6 +742,11 @@ "relations": [ { "path": "src/app_runtime/control/http_channel.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel._action_response", "metadata": { "edge_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", "edge_type": "dataflow_slice", @@ -778,6 +787,11 @@ }, { "path": "src/app_runtime/control/http_channel.py", + "start_line": 15, + "end_line": 22, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel.start", "metadata": { "edge_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", "edge_type": "dataflow_slice", @@ -818,6 +832,11 @@ }, { "path": "src/app_runtime/control/http_channel.py", + "start_line": 14, + "end_line": 34, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel._health_response", "metadata": { "edge_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", "edge_type": "dataflow_slice", @@ -858,6 +877,11 @@ }, { "path": "src/app_runtime/control/http_channel.py", + "start_line": 15, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel.stop", "metadata": { "edge_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", "edge_type": "dataflow_slice", @@ -897,6 +921,7 @@ "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.stop" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -1454,8 +1479,8 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 31, - "C0_SOURCE_CHUNKS": 15, + "C1_SYMBOL_CATALOG": 26, + "C0_SOURCE_CHUNKS": 16, "C2_DEPENDENCY_GRAPH": 17 } } @@ -1470,6 +1495,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -1484,7 +1512,7 @@ "C0_SOURCE_CHUNKS", "C2_DEPENDENCY_GRAPH" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -1525,8 +1553,44 @@ "failure_reasons": [], "evidence_count": 13 }, + "evidence_gate_input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 2, + "retrieval": 60, + "pre_evidence_gate": 1, + "llm": 3231, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -2028,6 +2092,150 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "token_usage": { + "prompt_name": "code_qa_explain_local_answer", + "tokens_in_estimate": 2071 + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 60 + }, + "output": { + "rag_count": 13, + "answer_path_rag_count": 13, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlChannel", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C2_DEPENDENCY_GRAPH": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 12, + "C2_DEPENDENCY_GRAPH": 4 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 26, + "C0_SOURCE_CHUNKS": 16, + "C2_DEPENDENCY_GRAPH": 17 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 13 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3231 + }, + "output": { + "prompt_name": "code_qa_explain_local_answer", + "answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.md new file mode 100644 index 0000000..5a9d240 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-local-http-channel.md @@ -0,0 +1,285 @@ +# plba-v3-explain-local-http-channel + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 13, + "llm_answer": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с переданным набором действий (ControlActionSet), а метод stop останавливает его. Свойство port возвращает текущий порт runner.\n\nВнутри класса определены два обработчика: _health_response проверяет здоровье канала, возвращая статус \"unhealthy\" если действия не установлены; \n_action_response предположительно обрабатывает запросы на выполнение действий, но его реализация в данном фрагменте не показана.", + "answer_mode": "answered", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "symbol_candidates": [ + "HttpControlChannel" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 60 + }, + "output": { + "rag_count": 13, + "answer_path_rag_count": 13, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlChannel", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C2_DEPENDENCY_GRAPH": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 12, + "C2_DEPENDENCY_GRAPH": 4 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 26, + "C0_SOURCE_CHUNKS": 16, + "C2_DEPENDENCY_GRAPH": 17 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 13 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3231 + }, + "output": { + "prompt_name": "code_qa_explain_local_answer", + "answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN_LOCAL", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", + "sub_intent": "EXPLAIN_LOCAL", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 13 + }, + "evidence_gate_input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и реализует HTTP-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI-приложения. \n\nМетод start запускает сервер с пер" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 2, + "retrieval": 60, + "pre_evidence_gate": 1, + "llm": 3231, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.json index 3a125c2..a6501f3 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-explain-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-explain-runtime-manager", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Объясни как работает класс RuntimeManager", @@ -10,8 +10,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Класс `RuntimeManager` играет ключевую роль в управлении выполнением приложений и координации различных компонентов системы. Его основная функция заключается в оркестрации действий, связанных с жизненным циклом приложения, включая инициализацию, запуск и остановку сервисов и модулей.\n\n**Ключевые шаги работы класса:**\n1. Инициализация конфигурации и состояния (`__init__`).\n2. Добавление конфигурационных файлов и настроек (`add_config_file`).\n3. Управление состоянием выполнения через чтение и запись атрибутов состояния (`configuration`, `_state`).\n4. Оркестровка вызова методов запуска и остановки для различных компонентов (`start`, `stop`).\n5. Участие в обработке данных потока и управлении потоками задач (`participates in dataflow slices`).\n\n**Опорные файлы:**\n- `src/app_runtime/core/runtime.py:18-179`\n- `src/app_runtime/control/service.py:12-52`\n- `src/app_runtime/control/base.py:21-28`\n- `src/app_runtime/control/base.py:14-18`", - "answer_mode": "answered", + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager.", + "answer_mode": "degraded", "path_scope": [], "symbol_candidates": [ "RuntimeManager" @@ -131,12 +131,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1277,6 +1281,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1317,6 +1326,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1357,6 +1371,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1397,6 +1416,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1437,6 +1461,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1477,6 +1506,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1516,37 +1550,83 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/core/runtime.py", + "title": "RuntimeManager", + "symbol": "RuntimeManager", + "role": "pipeline_stage", + "confidence": 0.67, + "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1574,6 +1654,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1597,6 +1684,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2866,11 +2987,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 51, - "C0_SOURCE_CHUNKS": 16, + "C1_SYMBOL_CATALOG": 494, + "C0_SOURCE_CHUNKS": 17, "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 54, - "C3_ENTRYPOINTS": 11 + "C2_DEPENDENCY_GRAPH": 55, + "C3_ENTRYPOINTS": 14 } } }, @@ -2885,7 +3006,10 @@ "C3_ENTRYPOINTS" ], "retrieval_sufficient": true, - "answer_mode": "normal", + "answer_mode": "degraded", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2900,7 +3024,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2953,8 +3077,46 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он является основным компонентом для управления жизненным циклом приложения и конфигурациями.\n\nМетоды:\n- Конструктор `__init__`: инициализирует объект RuntimeManager и принимает конфигурацию.\n- `add_config_file`: добавляет ф", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 2, + "retrieval": 597, + "pre_evidence_gate": 1, + "llm": 5865, + "post_evidence_gate": 2, + "repair": 4529, + "post_evidence_gate_recheck": 2 + } }, "rag_rows": [ { @@ -4146,9 +4308,165 @@ } ], "validation": { - "passed": true, - "action": "return", - "reasons": [] - } + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ] + }, + "token_usage": { + "prompt_name": "code_qa_explain_answer", + "tokens_in_estimate": 4504 + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 597 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 494, + "C0_SOURCE_CHUNKS": 17, + "C4_SEMANTIC_ROLES": 14, + "C2_DEPENDENCY_GRAPH": 55, + "C3_ENTRYPOINTS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 5865 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он является основным компонентом для управления жизненным циклом приложения и конфигурациями.\n\nМетоды:\n- Конструктор `__init__`: инициализирует объект RuntimeManager и принимает конфигурацию.\n- `add_config_file`: добавляет ф", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 2, + "post_evidence_gate_recheck": 2, + "repair": 4529 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он является основным компонентом для управления жизненным циклом приложения и конфигурациями.\n\nМетоды:\n- Конструктор `__init__`: инициализирует объект RuntimeManager и принимает конфигурацию.\n- `add_config_file`: добавляет ф", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.md new file mode 100644 index 0000000..f45eef0 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-explain-runtime-manager.md @@ -0,0 +1,311 @@ +# plba-v3-explain-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Объясни как работает класс RuntimeManager + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager.", + "answer_mode": "degraded", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 597 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 494, + "C0_SOURCE_CHUNKS": 17, + "C4_SEMANTIC_ROLES": 14, + "C2_DEPENDENCY_GRAPH": 55, + "C3_ENTRYPOINTS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 5865 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он является основным компонентом для управления жизненным циклом приложения и конфигурациями.\n\nМетоды:\n- Конструктор `__init__`: инициализирует объект RuntimeManager и принимает конфигурацию.\n- `add_config_file`: добавляет ф", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 2, + "post_evidence_gate_recheck": 2, + "repair": 4529 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он является основным компонентом для управления жизненным циклом приложения и конфигурациями.\n\nМетоды:\n- Конструктор `__init__`: инициализирует объект RuntimeManager и принимает конфигурацию.\n- `add_config_file`: добавляет ф", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "degraded", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни как работает класс RuntimeManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он является основным компонентом для управления жизненным циклом приложения и конфигурациями.\n\nМетоды:\n- Конструктор `__init__`: инициализирует объект RuntimeManager и принимает конфигурацию.\n- `add_config_file`: добавляет ф", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 2, + "retrieval": 597, + "pre_evidence_gate": 1, + "llm": 5865, + "post_evidence_gate": 2, + "repair": 4529, + "post_evidence_gate_recheck": 2 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.json similarity index 75% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.json index 4c8ea75..a37e36a 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-find-entrypoints-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-find-entrypoints-health-endpoint", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где health endpoint?", @@ -9,8 +9,8 @@ "sub_intent": "FIND_ENTRYPOINTS", "graph_id": "CodeQAGraph", "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "health endpoint: \n- src/app_runtime/control/http_app.py:38-42 (app.post)\n- src/app_runtime/control/http_app.py:31-34 (app.get)", + "rag_count": 10, + "llm_answer": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -22,10 +22,8 @@ "C0_SOURCE_CHUNKS" ] }, - "passed": false, - "mismatches": [ - "llm: expected answer to contain 'GET /health'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Где health endpoint?", "router_result": { @@ -122,12 +120,9 @@ } }, "symbol_resolution": { - "status": "pending", + "status": "not_found", "resolved_symbol": null, - "alternatives": [ - "health", - "endpoint" - ], + "alternatives": [], "confidence": 0.0 }, "evidence_policy": { @@ -491,28 +486,22 @@ "last_modified": null, "staleness_score": null } - } - ], - "relations": [], - "entrypoints": [ + }, { + "layer": "C0_SOURCE_CHUNKS", "path": "src/app_runtime/control/http_app.py", - "title": "app.post", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "start_line": 15, + "end_line": 53, "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", "repo_id": "plba", + "artifact_type": null, "section": null, "doc_id": null, "doc_version": null, @@ -521,10 +510,21 @@ "last_modified": null, "staleness_score": null } - }, + } + ], + "relations": [], + "semantic_hints": [], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -552,6 +552,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -575,6 +582,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -587,7 +628,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -884,6 +925,36 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "retrieval_report": { @@ -893,18 +964,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -912,9 +985,16 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 22, - "C0_SOURCE_CHUNKS": 20 - } + "C3_ENTRYPOINTS": 34, + "C0_SOURCE_CHUNKS": 15 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, "diagnostics": { @@ -926,6 +1006,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -937,7 +1020,7 @@ "C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -958,7 +1041,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -967,10 +1050,44 @@ "evidence_gate_decision": { "sufficient": true, "failure_reasons": [], - "evidence_count": 9 + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 64, + "pre_evidence_gate": 1, + "llm": 1406, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -1263,12 +1380,179 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "validation": { "passed": true, "action": "return", "reasons": [] - } + }, + "token_usage": { + "prompt_name": "code_qa_find_entrypoints_answer", + "tokens_in_estimate": 2531 + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 64 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 34, + "C0_SOURCE_CHUNKS": 15 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1406 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.md new file mode 100644 index 0000000..1d8636e --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-entrypoints-health-endpoint.md @@ -0,0 +1,261 @@ +# plba-v3-find-entrypoints-health-endpoint + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где health endpoint? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 10, + "llm_answer": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "health", + "endpoint" + ], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 64 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 34, + "C0_SOURCE_CHUNKS": 15 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1406 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где health endpoint?", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 7, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 64, + "pre_evidence_gate": 1, + "llm": 1406, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.json similarity index 94% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.json index 99d0936..5e4a159 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-find-tests-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-find-tests-runtime-manager", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для RuntimeManager?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:12-12\n- tests/test_business_control_actions.py:14-14", + "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -136,12 +136,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1017,6 +1021,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1057,6 +1066,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1097,6 +1111,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1137,6 +1156,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1177,6 +1201,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1217,6 +1246,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1256,6 +1290,7 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [ { @@ -2188,9 +2223,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 45, - "C2_DEPENDENCY_GRAPH": 53, - "C0_SOURCE_CHUNKS": 17 + "C1_SYMBOL_CATALOG": 50, + "C2_DEPENDENCY_GRAPH": 59, + "C0_SOURCE_CHUNKS": 22 } } }, @@ -2204,6 +2239,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2216,7 +2254,7 @@ "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2255,8 +2293,42 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 132, + "pre_evidence_gate": 1, + "llm": 1662, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -3128,6 +3200,142 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "token_usage": { + "prompt_name": "code_qa_find_tests_answer", + "tokens_in_estimate": 3660 + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 132 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 50, + "C2_DEPENDENCY_GRAPH": 59, + "C0_SOURCE_CHUNKS": 22 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1662 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.md new file mode 100644 index 0000000..32ab13f --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-find-tests-runtime-manager.md @@ -0,0 +1,269 @@ +# plba-v3-find-tests-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для RuntimeManager? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 132 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 50, + "C2_DEPENDENCY_GRAPH": 59, + "C0_SOURCE_CHUNKS": 22 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1662 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для RuntimeManager?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие сущности контроля, которые взаимодействуют с `RuntimeManager`." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 132, + "pre_evidence_gate": 1, + "llm": 1662, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.json similarity index 85% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.json index a6b476d..1f07d15 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-open-file-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-open-file-runtime", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/app_runtime/core/runtime.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 1, - "llm_answer": "Виден класс `RuntimeManager` с методом `__init__`, принимающим несколько параметров. Фиксированы также константы `ACTION_TIMEOUT_SECONDS` и `ACTION_POLL_INTERVAL_SECONDS`.", + "llm_answer": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип `LogManager`\n- `workers`: тип `WorkerSupervisor`\n- `control_plane`: тип `ControlPlaneService`\n\nТакже определены константы таймаутов:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`", "answer_mode": "answered", "path_scope": [ "src/app_runtime/core/runtime.py" @@ -250,6 +250,7 @@ } ], "relations": [], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -322,7 +323,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 221 + "C0_SOURCE_CHUNKS": 132 } } }, @@ -334,6 +335,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -373,12 +377,43 @@ "failure_reasons": [], "evidence_count": 1 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 221, - "pre_evidence_gate": 0, - "llm": 578 + "router": 1, + "retrieval": 132, + "pre_evidence_gate": 1, + "llm": 3550, + "post_evidence_gate": 2 } }, "rag_rows": [ @@ -418,12 +453,16 @@ "action": "return", "reasons": [] }, + "token_usage": { + "prompt_name": "code_qa_open_file_answer", + "tokens_in_estimate": 1128 + }, "steps": [ { "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -436,7 +475,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 221 + "retrieval": 132 }, "output": { "rag_count": 1, @@ -476,7 +515,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 221 + "C0_SOURCE_CHUNKS": 132 } } }, @@ -484,36 +523,64 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 1 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 578 + "llm": 3550 }, "output": { "prompt_name": "code_qa_open_file_answer", - "answer_preview": "Виден класс `RuntimeManager` с методом `__init__`, принимающим несколько параметров. Фиксированы также константы `ACTION_TIMEOUT_SECONDS` и `ACTION_POLL_INTERVAL_SECONDS`." + "answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 2, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип" } } ] diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.md new file mode 100644 index 0000000..fcc93ea --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-open-file-runtime.md @@ -0,0 +1,250 @@ +# plba-v3-open-file-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/app_runtime/core/runtime.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 1, + "llm_answer": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип `LogManager`\n- `workers`: тип `WorkerSupervisor`\n- `control_plane`: тип `ControlPlaneService`\n\nТакже определены константы таймаутов:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`", + "answer_mode": "answered", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 132 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 132 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3550 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 2, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 1 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько классов полей с умолчательными сервисами:\n- `configuration`: тип `ConfigurationManager`\n- `services`: тип `ServiceContainer`\n- `traces`: тип `TraceService`\n- `health`: тип `HealthRegistry`\n- `logs`: тип" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 132, + "pre_evidence_gate": 1, + "llm": 3550, + "post_evidence_gate": 2 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json rename to tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.json index 86a424b..222bed8 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.json @@ -1,6 +1,6 @@ { - "case_id": "plba-v2-trace-flow-runtime-start", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "case_id": "plba-v3-trace-flow-runtime-start", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Покажи поток выполнения при запуске RuntimeManager", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 37, - "llm_answer": "1. Запускается `RuntimeManager` через импорт в `bootstrap.py` (`src/plba/bootstrap.py:4`).\n2. Далее, в `control/service.py`, происходит повторный импорт и переопределение переменной `RuntimeManager` как `app_runtime.core.runtime.RuntimeManager` (`src/app_runtime/control/service.py:9`).\n3. В файле `core/runtime.py` начинается определение класса `RuntimeManager`. Этот класс управляет состоянием приложения и участвует в управлении жизненным циклом различных сервисов и модулей (`src/app_runtime/core/runtime.py:18-179`).\n4. Из `__init__.py` модуля `plba` (`src/plba/__init__.py:16`) импортируется другой экземпляр `RuntimeManager`.\n5. Затем идет обращение к инициализации объекта `ControlPlaneService` в модуле `control/service.py` (`src/app_runtime/control/service.py:12-52`), который регистрирует каналы управления.\n6. Контроллер канала управления определяется в `base.py` файла `control` и имеет методы для запуска и остановки каналов (`src/app_runtime/control/base.py:21-28`).\n7. В `control/http_channel.py` создается объект `HttpControlChannel`, управляющий HTTP-запросами с использованием библиотеки uvicorn (`src/app_runtime/control/http_channel.py:12-57`).\n8. Модуль `control/http_app.py` создает фабрику приложений для обработки HTTP-запросов, связанных с управлением состоянием системы (`src/app_runtime/control/http_app.py:15-53`).\n9. Инициализация конфигурации и параметров происходит в методах `_register_core_services` и `_start_async` внутри класса `RuntimeManager` (`src/app_runtime/core/runtime.py:32-127`).\n\nПолный путь вызова:\n\n1. `src/plba/bootstrap.py`\n2. `src/app_runtime/control/service.py`\n3. `src/app_runtime/core/runtime.py`\n4. `src/plba/__init__.py`\n5. `src/app_runtime/control/service.py`\n6. `src/app_runtime/control/base.py`\n7. `src/app_runtime/control/http_channel.py`\n8. `src/app_runtime/control/http_app.py`\n9. `src/app_runtime/core/runtime.py`", + "llm_answer": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связях внутри класса `RuntimeManager`. \nКонкретные реализации логики запуска находятся в файле `src/app_runtime/core/runtime.py`, строки 32–127.\n\nПоток выполнения полностью восстанавливается по данным контекстного фрагмента.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -120,12 +120,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1431,6 +1435,11 @@ "relations": [ { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1471,6 +1480,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 33, + "end_line": 39, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.__init__", "metadata": { "edge_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", "edge_type": "dataflow_slice", @@ -1511,6 +1525,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1551,6 +1570,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1591,6 +1615,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 59, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.start", "metadata": { "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", "edge_type": "dataflow_slice", @@ -1631,6 +1660,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 127, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager._register_core_services", "metadata": { "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", "edge_type": "dataflow_slice", @@ -1671,6 +1705,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1711,6 +1750,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1751,6 +1795,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1791,6 +1840,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 33, + "end_line": 127, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager._register_core_services", "metadata": { "edge_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", "edge_type": "dataflow_slice", @@ -1830,37 +1884,83 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager._register_core_services" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/core/runtime.py", + "title": "RuntimeManager", + "symbol": "RuntimeManager", + "role": "pipeline_stage", + "confidence": 0.67, + "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1888,6 +1988,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1911,6 +2018,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3380,11 +3521,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 50, - "C0_SOURCE_CHUNKS": 69, - "C4_SEMANTIC_ROLES": 82, - "C2_DEPENDENCY_GRAPH": 78, - "C3_ENTRYPOINTS": 11 + "C1_SYMBOL_CATALOG": 59, + "C0_SOURCE_CHUNKS": 45, + "C4_SEMANTIC_ROLES": 21, + "C2_DEPENDENCY_GRAPH": 62, + "C3_ENTRYPOINTS": 21 } } }, @@ -3400,6 +3541,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3414,7 +3558,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -3467,8 +3611,42 @@ "failure_reasons": [], "evidence_count": 37 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 2, + "retrieval": 211, + "pre_evidence_gate": 1, + "llm": 3158, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -4863,6 +5041,158 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "token_usage": { + "prompt_name": "code_qa_trace_flow_answer", + "tokens_in_estimate": 4310 + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 211 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 59, + "C0_SOURCE_CHUNKS": 45, + "C4_SEMANTIC_ROLES": 21, + "C2_DEPENDENCY_GRAPH": 62, + "C3_ENTRYPOINTS": 21 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3158 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.md new file mode 100644 index 0000000..8dade62 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/full_chain_plba_code_subintents_one_per_subintent_plba-v3-trace-flow-runtime-start.md @@ -0,0 +1,305 @@ +# plba-v3-trace-flow-runtime-start + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_one_per_subintent.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Покажи поток выполнения при запуске RuntimeManager + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 37, + "llm_answer": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связях внутри класса `RuntimeManager`. \nКонкретные реализации логики запуска находятся в файле `src/app_runtime/core/runtime.py`, строки 32–127.\n\nПоток выполнения полностью восстанавливается по данным контекстного фрагмента.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 211 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 59, + "C0_SOURCE_CHUNKS": 45, + "C4_SEMANTIC_ROLES": 21, + "C2_DEPENDENCY_GRAPH": 62, + "C3_ENTRYPOINTS": 21 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3158 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Покажи поток выполнения при запуске RuntimeManager", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 10, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 37 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через `add_config_file`.\n2. Инициализация сервисов.\n3. Регистрация основных служб через `_register_core_services`.\n4. Запуск менеджера с помощью метода `start`.\n\nЭти этапы основаны на сигнатурах методов и их связ" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 2, + "retrieval": 211, + "pre_evidence_gate": 1, + "llm": 3158, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/summary.md b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/summary.md new file mode 100644 index 0000000..c6bb4a5 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/manual_run/20260312_193339/summary.md @@ -0,0 +1,36 @@ +# pipeline_setup_v3 summary + +Passed: 7/7 + +| File | Case | Mode | Query | Actual sub-intent | RAG layers | Tokens | Pass | +|------|------|------|-------|-------------------|------------|--------|------| +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | 1128 | ✓ | +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | 4504 | ✓ | +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | 2071 | ✓ | +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | 3660 | ✓ | +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:7, C3_ENTRYPOINTS:3 | 2531 | ✓ | +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | 4310 | ✓ | +| full_chain_plba_code_subintents_one_per_subintent.yaml | plba-v3-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | 4061 | ✓ | + +## LLM Answers +- **plba-v3-open-file-runtime** + Query: Открой файл src/app_runtime/core/runtime.py + > В файле \`src/app\_runtime/core/runtime.py\` определён класс \`RuntimeManager\`. У него есть несколько классов полей с умолчательными сервисами: \- \`configuration\`: тип \`ConfigurationManager\` \- \`services\`: тип \`ServiceContainer\` \- \`traces\`: тип \`TraceService\` \- \`health\`: тип \`HealthRegistry\` \- \`logs\`: тип \`LogManager\` \- \`workers\`: тип \`WorkerSupervisor\` \- \`control\_plane\`: тип \`ControlPlaneService\` Также определены константы таймаутов: \- \`ACTION\_TIMEOUT\_SECONDS = 10.0\` \- \`ACTION\_POLL\_INTERVAL\_SECONDS = 0.05\` +- **plba-v3-explain-runtime-manager** + Query: Объясни как работает класс RuntimeManager + > Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager. +- **plba-v3-explain-local-http-channel** + Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? + > Класс HttpControlChannel наследует ControlChannel и реализует HTTP\-канал управления. Он принимает хост, порт и таймаут при инициализации, создаёт экземпляр UvicornThreadRunner для запуска сервера и использует HttpControlAppFactory для создания FastAPI\-приложения. Метод start запускает сервер с переданным набором действий \(ControlActionSet\), а метод stop останавливает его. Свойство port возвращает текущий порт runner. Внутри класса определены два обработчика: \_health\_response проверяет здоровье канала, возвращая статус "unhealthy" если действия не установлены; \_action\_response предположительно обрабатывает запросы на выполнение действий, но его реализация в данном фрагменте не показана. +- **plba-v3-find-tests-runtime-manager** + Query: Где тесты для RuntimeManager? + > Прямые тесты для \`RuntimeManager\` находятся в файле \`tests/test\_runtime.py\`. Косвенные тесты: \- В файле \`tests/test\_business\_control\_actions.py\` есть тесты, использующие сущности контроля, которые взаимодействуют с \`RuntimeManager\`. +- **plba-v3-find-entrypoints-health-endpoint** + Query: Где health endpoint? + > Подтверждённая точка входа для health endpoint: GET /health, declared in src/app\_runtime/control/http\_app.py, lines 31\-34, handler function named 'health'. +- **plba-v3-trace-flow-runtime-start** + Query: Покажи поток выполнения при запуске RuntimeManager + > При запуске \`RuntimeManager\` выполняются следующие шаги: 1. Инициализация конфигурации через \`add\_config\_file\`. 2. Инициализация сервисов. 3. Регистрация основных служб через \`\_register\_core\_services\`. 4. Запуск менеджера с помощью метода \`start\`. Эти этапы основаны на сигнатурах методов и их связях внутри класса \`RuntimeManager\`. Конкретные реализации логики запуска находятся в файле \`src/app\_runtime/core/runtime.py\`, строки 32–127. Поток выполнения полностью восстанавливается по данным контекстного фрагмента. +- **plba-v3-architecture-runtime-manager** + Query: Какие компоненты участвуют в RuntimeManager? + > Компоненты, участвующие в подсистеме RuntimeManager: \- \*\*RuntimeManager\*\* \(src/app\_runtime/core/runtime.py:18\-179\) \- \*\*ControlPlaneService.\_\_init\_\_\*\* \(src/app\_runtime/control/service.py:14\-51\) \- \*\*RuntimeManager.\_\_init\_\_\*\* \(src/app\_runtime/core/runtime.py:32\-127\) \- \*\*ControlPlaneService.\_start\_async\*\* \(src/app\_runtime/control/service.py:14\-47\) \- \*\*RuntimeManager.start\*\* \(src/app\_runtime/core/runtime.py:32\-59\) \- \*\*ControlPlaneService.start\*\* \(src/app\_runtime/control/service.py:14\-20\) \- \*\*ControlPlaneService.stop\*\* \(src/app\_runtime/control/service.py:14\-25\) \- \*\*ControlPlaneService.\_stop\_async\*\* \(src/app\_runtime/control/service.py:14\-51\) \- \*\*RuntimeManager.add\_config\_file\*\* \(src/app\_runtime/core/runtime.py:32\-52\) \- \*\*ControlPlaneService.register\_channel\*\* \(src/app\_runtime/control/service.py:14\-17\) Связи между компонентами: \- \*\*ControlPlaneService.\_\_init\_\_ dataflow\_slice… \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md deleted file mode 100644 index 37bd2fd..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-architecture-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в ControlPlaneService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Подтвержденные связи и роли компонентов в контексте ControlPlaneService:\n\n### Компоненты и их роли\n\n1. **ControlPlaneService**\n - Роль: pipeline_stage\n - Описание: Инициализирует каналы управления и управляет ими.\n \n2. **ControlChannel**\n - Роль: model\n - Описание: Абстрактный класс для каналов управления с методами старта и остановки.\n\n3. **ControlActionSet**\n - Роль: model\n - Описание: Представляет набор действий контроля.\n\n4. **UvicornThreadRunner**\n - Роль: pipeline_stage\n - Описание: Управляет uvicorn сервером и участвует в потоках данных.\n\n5. **HttpControlChannel**\n - Роль: pipeline_stage\n - Описание: Канал управления HTTP-соединениями, участвующий в потоках данных.\n\n6. **HttpControlAppFactory**\n - Роль: factory\n - Описание: Фабрика для создания fastAPI приложений.\n\n7. **WorkflowPersistence**\n - Роль: pipeline_stage\n - Описание: Хранит информацию о процессах и взаимодействует с ними.\n\n8. **InMemoryTaskQueue**\n - Роль: pipeline_stage\n - Описание: Очередь задач, используемая для хранения промежуточных результатов.\n\n9. **ConfigFileLoader**\n - Роль: pipeline_stage\n - Описание: Загружает конфигурационные файлы и участвует в управлении состоянием приложения.\n\n10. **TraceContextStore**\n - Роль: pipeline_stage\n - Описание: Сохраняет контекст трассировки и управляет им.\n\n11. **WorkerSupervisor**\n - Роль: pipeline_stage\n - Описание: Наблюдает за рабочими процессами и обеспечивает их корректное выполнение.\n\n12. **WorkflowEngine**\n - Роль: pipeline_stage\n - Описание: Координирует выполнение рабочих процессов и управление ими.\n\n### Ограничения и замечания\n\nВсе перечисленные компоненты прямо или косвенно связаны с ControlPlaneService через зависимости или вызовы методов внутри ControlPlaneService. Они активно участвуют в его работе и обеспечивают функциональность и инфраструктуру, необходимую для выполнения его обязанностей.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md deleted file mode 100644 index 4aedcac..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-architecture-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в RuntimeManager? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "### Компоненты, участвующие в RuntimeManager\n\n#### Подтвержденные связи\n1. **RuntimeManager**\n - Role: Pipeline Stage\n - Responsibilities:\n - Manager responsibilities\n - Orchestration of role-like calls\n - State attribute reading/writing\n - Participation in dataflow slices\n\n2. **ControlPlaneService**\n - Role: Pipeline Stage\n - Responsibilities:\n - Service responsibilities\n - State attribute reading/writing\n - Participation in dataflow slices\n\n3. **UvicornThreadRunner**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n4. **HttpControlChannel**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n5. **WorkflowPersistence**\n - Role: Pipeline Stage\n - Responsibilities:\n - Orchestration of role-like calls\n - State attribute reading/writing\n - Participation in dataflow slices\n\n6. **InMemoryTaskQueue**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n7. **ConfigFileLoader**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n8. **TraceContextStore**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n9. **WorkerSupervisor**\n - Role: Pipeline Stage\n - Responsibilities:\n - State attribute reading/writing\n - Participation in dataflow slices\n\n### Ограничения найденного контекста\n- Все перечисленные компоненты являются участниками данных потоков выполнения (dataflow slices).\n- Каждый компонент выполняет операции чтения и записи состояния атрибутов.\n- Некоторые из них выполняют дополнительные обязанности, такие как участие в оркестрации или инициировании ролей.\n\nТаким образом, участники RuntimeManager включают перечисленные выше компоненты.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md deleted file mode 100644 index d04c416..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Что делает функция create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Функция `create_runtime` инициализирует и настраивает менеджер выполнения приложения.\n\n**Ключевые шаги:**\n1. Инициализация менеджера выполнения (`RuntimeManager()`).\n2. Добавление конфигурационного файла, если указан путь (`add_config_file`).\n3. Регистрация HTTP-канала управления, если включен режим управления (`register_channel`).\n4. Регистрация модуля приложения в менеджере выполнения (`register_module`).\n\n**Опорные файлы:**\n- `src/plba/bootstrap.py:8-29`\n\nЭтот процесс позволяет настроить и запустить приложение с учетом заданных конфигураций и режимов управления.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json deleted file mode 100644 index a2ca778..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json +++ /dev/null @@ -1,2033 +0,0 @@ -{ - "case_id": "plba-v2-explain-local-http-channel", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN_LOCAL", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` предназначен для управления HTTP каналом контроля в приложении.\n\n**Ключевые шаги его реализации:**\n1. Инициализация (`__init__`) – принимает параметры хоста, порта и тайм-аута, создаёт внутренние объекты управления и инициализирует состояние канала.\n2. Запуск (`start`) – запускает сервер с заданными действиями контроля, создавая приложение и вызывая runner для запуска сервера.\n3. Остановка (`stop`) – останавливает запущенный сервер.\n4. Свойство `port` – возвращает порт, используемый сервером.\n5. Метод `_health_response` – генерирует ответ о состоянии здоровья системы (здоров или нет).\n\nОпорные файлы:\n- `src/app_runtime/control/http_channel.py:12-57` (определение класса и методов)\n- `src/app_runtime/control/http_channel.py:13-17` (инициализация)\n- `src/app_runtime/control/http_channel.py:19-22` (запуск)", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "symbol_candidates": [ - "HttpControlChannel" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "normalized": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "sub_intent": "EXPLAIN_LOCAL", - "negations": [], - "expansions": [ - "file", - "HttpControlChannel" - ], - "keyword_hints": [ - "src/app_runtime/control/http_channel.py", - "HttpControlChannel" - ], - "path_hints": [ - "src/app_runtime/control/http_channel.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [ - "HttpControlChannel" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/app_runtime/control/http_channel.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 15, - "end": 54 - }, - "confidence": 0.95 - }, - { - "type": "SYMBOL", - "value": "HttpControlChannel", - "source": "user_text", - "subtype": null, - "span": { - "start": 61, - "end": 79 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 9, - "end": 14 - }, - "confidence": 0.9 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 55, - "end": 60 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "HttpControlChannel" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": false, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "sub_intent": "EXPLAIN_LOCAL", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "keyword_hints": [ - "src/app_runtime/control/http_channel.py", - "HttpControlChannel" - ], - "symbol_candidates": [ - "HttpControlChannel" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "normalized": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "sub_intent": "EXPLAIN_LOCAL", - "negations": [], - "expansions": [ - "file", - "HttpControlChannel" - ], - "keyword_hints": [ - "src/app_runtime/control/http_channel.py", - "HttpControlChannel" - ], - "path_hints": [ - "src/app_runtime/control/http_channel.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [ - "HttpControlChannel" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/app_runtime/control/http_channel.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 15, - "end": 54 - }, - "confidence": 0.95 - }, - { - "type": "SYMBOL", - "value": "HttpControlChannel", - "source": "user_text", - "subtype": null, - "span": { - "start": 61, - "end": 79 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 9, - "end": 14 - }, - "confidence": 0.9 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 55, - "end": 60 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "ControlChannel", - "ControlActionSet", - "JSONResponse", - "HttpControlAppFactory", - "UvicornThreadRunner", - "HttpControlChannel", - "HttpControlChannel.__init__", - "HttpControlChannel.start" - ], - "resolved_symbol": "HttpControlChannel", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/app_runtime/control/http_channel.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "6e69a934202b6e11891af8fb72b2033e8ae3071eb7577c64f5545b5b7ddfb51e", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "JSONResponse", - "content": "const JSONResponse\nJSONResponse = fastapi.responses.JSONResponse", - "start_line": 5, - "end_line": 5, - "metadata": { - "symbol_id": "238f600ea55013e25a3e1451f7fd65caabea125b314b89247900cdab5b801a23", - "qname": "JSONResponse", - "kind": "const", - "signature": "JSONResponse = fastapi.responses.JSONResponse", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlAppFactory", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "start_line": 8, - "end_line": 8, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "UvicornThreadRunner", - "content": "const UvicornThreadRunner\nUvicornThreadRunner = app_runtime.control.http_runner.UvicornThreadRunner", - "start_line": 9, - "end_line": 9, - "metadata": { - "symbol_id": "c6ee53f4ff75d5b34ee95854cb63bb3ecfa163023717cd969b8cba937a0cd3b3", - "qname": "UvicornThreadRunner", - "kind": "const", - "signature": "UvicornThreadRunner = app_runtime.control.http_runner.UvicornThreadRunner", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "class HttpControlChannel\nHttpControlChannel(ControlChannel)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "qname": "HttpControlChannel", - "kind": "class", - "signature": "HttpControlChannel(ControlChannel)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel.__init__", - "content": "method HttpControlChannel.__init__\n__init__(self, host, port, timeout)", - "start_line": 13, - "end_line": 17, - "metadata": { - "symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "qname": "HttpControlChannel.__init__", - "kind": "method", - "signature": "__init__(self, host, port, timeout)", - "parent_symbol_id": "HttpControlChannel", - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel.start", - "content": "method HttpControlChannel.start\nstart(self, actions)", - "start_line": 19, - "end_line": 22, - "metadata": { - "symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "qname": "HttpControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "HttpControlChannel", - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel.__init__:dataflow_slice", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._action_response", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954", - "dst_ref": "HttpControlChannel._action_response", - "resolution": "resolved", - "slice_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._action_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel.__init__:dataflow_slice", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.start", - "start_line": 15, - "end_line": 22, - "metadata": { - "edge_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "dst_ref": "HttpControlChannel.start", - "resolution": "resolved", - "slice_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.start" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel.__init__:dataflow_slice", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._health_response", - "start_line": 14, - "end_line": 34, - "metadata": { - "edge_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a", - "dst_ref": "HttpControlChannel._health_response", - "resolution": "resolved", - "slice_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._health_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel.__init__:dataflow_slice", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.stop", - "start_line": 15, - "end_line": 25, - "metadata": { - "edge_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3", - "dst_ref": "HttpControlChannel.stop", - "resolution": "resolved", - "slice_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.stop" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/http_channel.py", - "metadata": { - "edge_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954", - "dst_ref": "HttpControlChannel._action_response", - "resolution": "resolved", - "slice_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._action_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._action_response" - }, - { - "path": "src/app_runtime/control/http_channel.py", - "metadata": { - "edge_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "dst_ref": "HttpControlChannel.start", - "resolution": "resolved", - "slice_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.start" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.start" - }, - { - "path": "src/app_runtime/control/http_channel.py", - "metadata": { - "edge_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a", - "dst_ref": "HttpControlChannel._health_response", - "resolution": "resolved", - "slice_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._health_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._health_response" - }, - { - "path": "src/app_runtime/control/http_channel.py", - "metadata": { - "edge_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3", - "dst_ref": "HttpControlChannel.stop", - "resolution": "resolved", - "slice_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.stop" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.stop" - } - ], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "6e69a934202b6e11891af8fb72b2033e8ae3071eb7577c64f5545b5b7ddfb51e", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const JSONResponse\nJSONResponse = fastapi.responses.JSONResponse", - "layer": "C1_SYMBOL_CATALOG", - "title": "JSONResponse", - "span_start": 5, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "238f600ea55013e25a3e1451f7fd65caabea125b314b89247900cdab5b801a23", - "qname": "JSONResponse", - "kind": "const", - "signature": "JSONResponse = fastapi.responses.JSONResponse", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 8, - "span_end": 8, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const UvicornThreadRunner\nUvicornThreadRunner = app_runtime.control.http_runner.UvicornThreadRunner", - "layer": "C1_SYMBOL_CATALOG", - "title": "UvicornThreadRunner", - "span_start": 9, - "span_end": 9, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "c6ee53f4ff75d5b34ee95854cb63bb3ecfa163023717cd969b8cba937a0cd3b3", - "qname": "UvicornThreadRunner", - "kind": "const", - "signature": "UvicornThreadRunner = app_runtime.control.http_runner.UvicornThreadRunner", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel\nHttpControlChannel(ControlChannel)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "qname": "HttpControlChannel", - "kind": "class", - "signature": "HttpControlChannel(ControlChannel)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "method HttpControlChannel.__init__\n__init__(self, host, port, timeout)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlChannel.__init__", - "span_start": 13, - "span_end": 17, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "qname": "HttpControlChannel.__init__", - "kind": "method", - "signature": "__init__(self, host, port, timeout)", - "parent_symbol_id": "HttpControlChannel", - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "method HttpControlChannel.start\nstart(self, actions)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlChannel.start", - "span_start": 19, - "span_end": 22, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "qname": "HttpControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "HttpControlChannel", - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._action_response", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954", - "dst_ref": "HttpControlChannel._action_response", - "resolution": "resolved", - "slice_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._action_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 15, - "span_end": 22, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "dst_ref": "HttpControlChannel.start", - "resolution": "resolved", - "slice_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.start" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._health_response", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 14, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a", - "dst_ref": "HttpControlChannel._health_response", - "resolution": "resolved", - "slice_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._health_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 15, - "span_end": 25, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3", - "dst_ref": "HttpControlChannel.stop", - "resolution": "resolved", - "slice_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.stop" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C2_DEPENDENCY_GRAPH": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 12, - "C2_DEPENDENCY_GRAPH": 4 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 38, - "C0_SOURCE_CHUNKS": 17, - "C2_DEPENDENCY_GRAPH": 17 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN_LOCAL", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "sub_intent": "EXPLAIN_LOCAL", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 13 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "6e69a934202b6e11891af8fb72b2033e8ae3071eb7577c64f5545b5b7ddfb51e", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const JSONResponse\nJSONResponse = fastapi.responses.JSONResponse", - "layer": "C1_SYMBOL_CATALOG", - "title": "JSONResponse", - "span_start": 5, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "238f600ea55013e25a3e1451f7fd65caabea125b314b89247900cdab5b801a23", - "qname": "JSONResponse", - "kind": "const", - "signature": "JSONResponse = fastapi.responses.JSONResponse", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 8, - "span_end": 8, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const UvicornThreadRunner\nUvicornThreadRunner = app_runtime.control.http_runner.UvicornThreadRunner", - "layer": "C1_SYMBOL_CATALOG", - "title": "UvicornThreadRunner", - "span_start": 9, - "span_end": 9, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "c6ee53f4ff75d5b34ee95854cb63bb3ecfa163023717cd969b8cba937a0cd3b3", - "qname": "UvicornThreadRunner", - "kind": "const", - "signature": "UvicornThreadRunner = app_runtime.control.http_runner.UvicornThreadRunner", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel\nHttpControlChannel(ControlChannel)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "qname": "HttpControlChannel", - "kind": "class", - "signature": "HttpControlChannel(ControlChannel)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "method HttpControlChannel.__init__\n__init__(self, host, port, timeout)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlChannel.__init__", - "span_start": 13, - "span_end": 17, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "qname": "HttpControlChannel.__init__", - "kind": "method", - "signature": "__init__(self, host, port, timeout)", - "parent_symbol_id": "HttpControlChannel", - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "method HttpControlChannel.start\nstart(self, actions)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlChannel.start", - "span_start": 19, - "span_end": 22, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "qname": "HttpControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "HttpControlChannel", - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._action_response", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954", - "dst_ref": "HttpControlChannel._action_response", - "resolution": "resolved", - "slice_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._action_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e64969024ccaeb34d8d91473fad07b3b3d341875846392e7a006406c7ada1954" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 15, - "span_end": 22, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0", - "dst_ref": "HttpControlChannel.start", - "resolution": "resolved", - "slice_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.start" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "d1933f04137f52535b6525f1b93ff2cd83bfb216b480e887e791ed1714cda8e0" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._timeout\n -> HttpControlChannel._health_response", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 14, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a", - "dst_ref": "HttpControlChannel._health_response", - "resolution": "resolved", - "slice_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._timeout", - "HttpControlChannel._health_response" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "e84bf04e9cd2127df235b7064d05f47e19f19a89c7c82f4c247231d4e8fa426a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlChannel.__init__:dataflow_slice", - "span_start": 15, - "span_end": 25, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "edge_type": "dataflow_slice", - "src_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "src_qname": "HttpControlChannel.__init__", - "dst_symbol_id": "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3", - "dst_ref": "HttpControlChannel.stop", - "resolution": "resolved", - "slice_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", - "root_symbol_id": "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "path_symbols": [ - "HttpControlChannel.__init__", - "HttpControlChannel._runner", - "HttpControlChannel.stop" - ], - "path_symbol_ids": [ - "8de037370533181832fa806ba2b86a458a7657ab5a95d9ffff90a649ada2dc3a", - "f29ab212620093d72be20e26c5a399624c7939a6056a728762ed3f84a250bfa3" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md deleted file mode 100644 index 10a3a23..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-local-http-channel - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN_LOCAL", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` предназначен для управления HTTP каналом контроля в приложении.\n\n**Ключевые шаги его реализации:**\n1. Инициализация (`__init__`) – принимает параметры хоста, порта и тайм-аута, создаёт внутренние объекты управления и инициализирует состояние канала.\n2. Запуск (`start`) – запускает сервер с заданными действиями контроля, создавая приложение и вызывая runner для запуска сервера.\n3. Остановка (`stop`) – останавливает запущенный сервер.\n4. Свойство `port` – возвращает порт, используемый сервером.\n5. Метод `_health_response` – генерирует ответ о состоянии здоровья системы (здоров или нет).\n\nОпорные файлы:\n- `src/app_runtime/control/http_channel.py:12-57` (определение класса и методов)\n- `src/app_runtime/control/http_channel.py:13-17` (инициализация)\n- `src/app_runtime/control/http_channel.py:19-22` (запуск)", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "symbol_candidates": [ - "HttpControlChannel" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json deleted file mode 100644 index 271b1e1..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json +++ /dev/null @@ -1,4092 +0,0 @@ -{ - "case_id": "plba-v2-explain-nonexistent-symbol", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Объясни класс RuntimeFactoryManager", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeFactoryManager` не указан напрямую в предоставленном коде. Однако, судя по контексту и взаимосвязям между классами:\n\n**Назначение класса:**\n- Управление фабрикой для создания экземпляров классов, связанных с управлением рабочим состоянием приложения.\n\n**Ключевые шаги:**\n1. Инициализация фабрики.\n2. Создание экземпляра соответствующего класса управления каналом (`ControlChannel`) или другого необходимого класса.\n3. Регистрация созданных каналов в сервисе управления каналами.\n\n**Опорные файлы:**\n- `src/app_runtime/control/base.py`: Объявление абстрактного базового класса `ControlChannel`.\n- `src/app_runtime/control/service.py`: Реализация сервиса управления каналами, который регистрирует созданные каналы.\n- `src/app_runtime/control/http_channel.py`: Определение канала HTTP, используемого для взаимодействия через HTTP-протокол.\n\nОбратите внимание, что прямое определение класса `RuntimeFactoryManager` отсутствует в представленном коде, поэтому информация о его назначении основана на логическом выводе и контексте использования других классов.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": false, - "mismatches": [ - "answer_mode: expected degraded, got answered", - "retrieval: expected empty rag, got 33 rows", - "llm: expected answer to contain 'не найдена'" - ], - "details": { - "query": "Объясни класс RuntimeFactoryManager", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Объясни класс RuntimeFactoryManager", - "normalized": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeFactoryManager" - ], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeFactoryManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 35 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 8, - "end": 13 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeFactoryManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Объясни класс RuntimeFactoryManager", - "normalized": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeFactoryManager" - ], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeFactoryManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 35 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 8, - "end": 13 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "ControlChannel", - "ControlChannel.stop", - "ControlActionSet", - "ControlPlaneService", - "ControlChannel.start" - ], - "resolved_symbol": null, - "symbol_resolution_status": "ambiguous", - "file_candidates": [ - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/service.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_app.py", - "src/plba/control.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/queue/in_memory.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "class ControlChannel\nControlChannel(ABC)", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.stop", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "start_line": 27, - "end_line": 28, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "class ControlActionSet\nControlActionSet", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.start", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "start_line": 23, - "end_line": 24, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/control.py", - "title": "src/plba/control.py:1-10", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "start_line": 1, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.register_channel:reads_attr", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.register_channel reads_attr self._channels.append" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel\nControlChannel(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 52, - "C0_SOURCE_CHUNKS": 22, - "C4_SEMANTIC_ROLES": 18, - "C2_DEPENDENCY_GRAPH": 59, - "C3_ENTRYPOINTS": 13 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel\nControlChannel(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md deleted file mode 100644 index 1c9d208..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md +++ /dev/null @@ -1,36 +0,0 @@ -# plba-v2-explain-nonexistent-symbol - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Объясни класс RuntimeFactoryManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeFactoryManager` не указан напрямую в предоставленном коде. Однако, судя по контексту и взаимосвязям между классами:\n\n**Назначение класса:**\n- Управление фабрикой для создания экземпляров классов, связанных с управлением рабочим состоянием приложения.\n\n**Ключевые шаги:**\n1. Инициализация фабрики.\n2. Создание экземпляра соответствующего класса управления каналом (`ControlChannel`) или другого необходимого класса.\n3. Регистрация созданных каналов в сервисе управления каналами.\n\n**Опорные файлы:**\n- `src/app_runtime/control/base.py`: Объявление абстрактного базового класса `ControlChannel`.\n- `src/app_runtime/control/service.py`: Реализация сервиса управления каналами, который регистрирует созданные каналы.\n- `src/app_runtime/control/http_channel.py`: Определение канала HTTP, используемого для взаимодействия через HTTP-протокол.\n\nОбратите внимание, что прямое определение класса `RuntimeFactoryManager` отсутствует в представленном коде, поэтому информация о его назначении основана на логическом выводе и контексте использования других классов.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- answer_mode: expected degraded, got answered -- retrieval: expected empty rag, got 33 rows -- llm: expected answer to contain 'не найдена' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md deleted file mode 100644 index 789c707..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Объясни как работает класс RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "**Класс `RuntimeManager`** отвечает за управление жизненным циклом приложения и координацию различных компонентов системы.\n\n### Ключевые шаги работы класса:\n1. **Инициализация конфигурации:** \n Класс инициализирует начальные настройки приложения, включая загрузку конфигурационных файлов.\n \n2. **Регистрация каналов управления:**\n Метод `register_channel` позволяет зарегистрировать каналы управления, которые будут использоваться для взаимодействия с различными компонентами системы.\n\n3. **Запуск и остановка системы:**\n Методы `start` и `stop` инициируют запуск и остановку всех зарегистрированных каналов управления, обеспечивая корректное завершение работы системы.\n\n4. **Сохранение состояния:**\n Метод `snapshot` создает снимок текущего состояния системы, который может быть использован для восстановления или анализа состояния в будущем.\n\n### Опорные файлы:\n- `src/app_runtime/core/runtime.py`: Определение и реализация класса `RuntimeManager`.\n- `src/app_runtime/control/service.py`: Реализация методов регистрации и запуска каналов управления.\n- `src/app_runtime/control/http_channel.py`: Управление HTTP-каналом для взаимодействия с внешним миром.\n\nЭтот класс играет центральную роль в управлении потоком выполнения и состоянием приложения, координируя работу различных компонентов и обеспечивая их синхронность и согласованность.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json deleted file mode 100644 index 5cdd980..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json +++ /dev/null @@ -1,4157 +0,0 @@ -{ - "case_id": "plba-v2-explain-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Объясни как работает класс TraceService", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "**Класс `TraceService`** предназначен для управления контекстом трассировки в приложении. Его основные функции включают создание нового контекста трассировки, получение текущего идентификатора трассировки и закрытие контекста.\n\n**Ключевые шаги работы класса:**\n1. **Инициализация:** При создании экземпляра `TraceService` задаются транспорт и хранилище контекста трассировки (по умолчанию используются заглушки).\n2. **Создание контекста:** Метод `create_context` создает новый контекст трассировки с заданными параметрами (идентификатор, родительский идентификатор, тип и атрибуты). Контекст сохраняется в хранилище.\n3. **Получение текущего идентификатора:** Метод `current_trace_id` возвращает текущий идентификатор трассировки.\n4. **Открытие контекста:** Метод `open_context` открывает новый контекст трассировки.\n5. **Закрытие контекста:** Метод `close_context` завершает текущую трассировку.\n\n**Опорные файлы:**\n- `src/app_runtime/tracing/service.py`: определение и реализация класса `TraceService`.\n- Другие файлы содержат декларации и зависимости, относящиеся к классу.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Объясни как работает класс TraceService", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Объясни как работает класс TraceService", - "normalized": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 27, - "end": 39 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 21, - "end": 26 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "TraceService" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "TraceService" - ], - "symbol_candidates": [ - "TraceService" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Объясни как работает класс TraceService", - "normalized": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 27, - "end": 39 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 21, - "end": 26 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "TraceService", - "TraceService.open_context", - "TraceService.create_context", - "TraceService.current_trace_id" - ], - "resolved_symbol": "TraceService", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/app_runtime/core/runtime.py", - "src/app_runtime/tracing/__init__.py", - "src/app_runtime/tracing/service.py", - "src/plba/tracing.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/workers/supervisor.py", - "src/app_runtime/control/http_app.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "start_line": 20, - "end_line": 20, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 14, - "end_line": 14, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "start_line": 39, - "end_line": 166, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/tracing.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.open_context", - "content": "method TraceService.open_context\nopen_context(self)", - "start_line": 66, - "end_line": 78, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.create_context", - "content": "method TraceService.create_context\ncreate_context(self)", - "start_line": 45, - "end_line": 63, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.current_trace_id", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "start_line": 80, - "end_line": 81, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceService", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "start_line": 39, - "end_line": 166, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "start_line": 169, - "end_line": 170, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/core/runtime.py", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "start_line": 18, - "end_line": 179, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/__init__.py", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "start_line": 1, - "end_line": 17, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/tracing.py", - "title": "src/plba/tracing.py:1-4", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService", - "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)", - "start_line": 39, - "end_line": 166, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "symbol_name": "TraceService", - "qname": "TraceService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 13, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "start_line": 42, - "end_line": 61, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "start_line": 42, - "end_line": 84, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "start_line": 42, - "end_line": 78, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "start_line": 41, - "end_line": 43, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "start_line": 42, - "end_line": 81, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "start_line": 42, - "end_line": 88, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 60, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "symbol_name": "TraceService", - "qname": "TraceService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 13, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 33, - "C0_SOURCE_CHUNKS": 13, - "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 45, - "C3_ENTRYPOINTS": 10 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 60, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "symbol_name": "TraceService", - "qname": "TraceService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 13, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md deleted file mode 100644 index 238b762..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Объясни как работает класс TraceService - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "**Класс `TraceService`** предназначен для управления контекстом трассировки в приложении. Его основные функции включают создание нового контекста трассировки, получение текущего идентификатора трассировки и закрытие контекста.\n\n**Ключевые шаги работы класса:**\n1. **Инициализация:** При создании экземпляра `TraceService` задаются транспорт и хранилище контекста трассировки (по умолчанию используются заглушки).\n2. **Создание контекста:** Метод `create_context` создает новый контекст трассировки с заданными параметрами (идентификатор, родительский идентификатор, тип и атрибуты). Контекст сохраняется в хранилище.\n3. **Получение текущего идентификатора:** Метод `current_trace_id` возвращает текущий идентификатор трассировки.\n4. **Открытие контекста:** Метод `open_context` открывает новый контекст трассировки.\n5. **Закрытие контекста:** Метод `close_context` завершает текущую трассировку.\n\n**Опорные файлы:**\n- `src/app_runtime/tracing/service.py`: определение и реализация класса `TraceService`.\n- Другие файлы содержат декларации и зависимости, относящиеся к классу.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json deleted file mode 100644 index 17a7e0e..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json +++ /dev/null @@ -1,1303 +0,0 @@ -{ - "case_id": "plba-v2-find-entrypoints-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Найди точки входа HTTP control plane", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "confirmed_entrypoints:\n- src/app_runtime/control/http_app.py:app.post (line range: 38-42)\n- src/app_runtime/control/http_app.py:app.get (line range: 31-34)\n- src/app_runtime/control/http_app.py:app.get (line range: 38-42)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Найди точки входа HTTP control plane", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Найди точки входа HTTP control plane", - "normalized": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "negations": [], - "expansions": [ - "HTTP", - "control", - "plane" - ], - "keyword_hints": [ - "HTTP", - "control", - "plane" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "HTTP", - "source": "user_text", - "subtype": null, - "span": { - "start": 18, - "end": 22 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "control", - "source": "user_text", - "subtype": null, - "span": { - "start": 23, - "end": 30 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "plane", - "source": "user_text", - "subtype": null, - "span": { - "start": 31, - "end": 36 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 12 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "HTTP", - "control", - "plane" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "keyword_hints": [ - "HTTP", - "control", - "plane" - ], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 12 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Найди точки входа HTTP control plane", - "normalized": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "negations": [], - "expansions": [ - "HTTP", - "control", - "plane" - ], - "keyword_hints": [ - "HTTP", - "control", - "plane" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "HTTP", - "source": "user_text", - "subtype": null, - "span": { - "start": 18, - "end": 22 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "control", - "source": "user_text", - "subtype": null, - "span": { - "start": 23, - "end": 30 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "plane", - "source": "user_text", - "subtype": null, - "span": { - "start": 31, - "end": 36 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [], - "resolved_symbol": null, - "symbol_resolution_status": "not_found", - "file_candidates": [ - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/http_runner.py" - ], - "code_chunks": [ - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 - }, - "filters_by_layer": { - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 11, - "C0_SOURCE_CHUNKS": 20 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 9 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md deleted file mode 100644 index a27500c..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md +++ /dev/null @@ -1,33 +0,0 @@ -# plba-v2-find-entrypoints-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Найди точки входа HTTP control plane - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "confirmed_entrypoints:\n- src/app_runtime/control/http_app.py:app.post (line range: 38-42)\n- src/app_runtime/control/http_app.py:app.get (line range: 31-34)\n- src/app_runtime/control/http_app.py:app.get (line range: 38-42)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md deleted file mode 100644 index 9dd7d51..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-entrypoints-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Где health endpoint? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "health endpoint: \n- src/app_runtime/control/http_app.py:38-42 (app.post)\n- src/app_runtime/control/http_app.py:31-34 (app.get)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "endpoint" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- llm: expected answer to contain 'GET /health' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md deleted file mode 100644 index 013c72c..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:342-405 (test_public_plba_package_exports_runtime_builder_and_worker_contract)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md deleted file mode 100644 index 7f1badd..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для RuntimeManager? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:12-12\n- tests/test_business_control_actions.py:14-14", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json deleted file mode 100644 index 478ef7b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json +++ /dev/null @@ -1,3134 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для TraceService?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "tests/test_runtime.py:test_trace_service_allows_messages_without_status \ntests/test_runtime.py:test_trace_service_writes_contexts_and_messages \ntests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для TraceService?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для TraceService?", - "normalized": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 26 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_trace_service", - "TestTraceService", - "TraceService" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "TraceService" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "TraceService" - ], - "symbol_candidates": [ - "TraceService" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_trace_service", - "TestTraceService", - "TraceService" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для TraceService?", - "normalized": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 26 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "TraceService", - "TraceService.open_context", - "TraceService.create_context", - "TraceService.current_trace_id" - ], - "resolved_symbol": "TraceService", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/app_runtime/core/runtime.py", - "src/app_runtime/tracing/__init__.py", - "src/app_runtime/tracing/service.py", - "src/plba/tracing.py", - "tests/test_runtime.py", - "src/app_runtime/contracts/__init__.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "start_line": 20, - "end_line": 20, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 14, - "end_line": 14, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "start_line": 39, - "end_line": 166, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/tracing.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.open_context", - "content": "method TraceService.open_context\nopen_context(self)", - "start_line": 66, - "end_line": 78, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.create_context", - "content": "method TraceService.create_context\ncreate_context(self)", - "start_line": 45, - "end_line": 63, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.current_trace_id", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "start_line": 80, - "end_line": 81, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "start_line": 42, - "end_line": 61, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "start_line": 42, - "end_line": 84, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "start_line": 42, - "end_line": 78, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "start_line": 41, - "end_line": 43, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "start_line": 42, - "end_line": 81, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "start_line": 42, - "end_line": 88, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/tracing.py", - "title": "src/plba/tracing.py:1-4", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optional-status\")\n manager.debug(\"debug without status\")\n manager.info(\"info without status\")\n manager.warning(\"warning without status\")\n manager.error(\"error without status\")\n\n assert [message.status for message in transport.messages] == [\"\", \"\", \"\", \"\"]\n assert all(message.trace_id == transport.contexts[0].trace_id for message in transport.messages)", - "start_line": 279, - "end_line": 293, - "metadata": { - "chunk_index": 11, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/__init__.py", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "start_line": 1, - "end_line": 17, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"parse\")\n manager.info(\"started\", status=\"ok\", attrs={\"attempt\": 1})\n\n assert len(transport.contexts) == 1\n assert len(transport.messages) == 1\n assert transport.contexts[0].alias == \"worker\"\n assert transport.messages[0].step == \"parse\"", - "start_line": 246, - "end_line": 259, - "metadata": { - "chunk_index": 9, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"validate\")\n manager.debug(\"validation details\", attrs={\"rule\": \"basic\"})\n manager.warning(\"validation warning\", status=\"degraded\", attrs={\"attempt\": 1})\n manager.error(\"integration failed\", status=\"failed\", attrs={\"integration\": \"crm\"})\n manager.exception(\"caught exception\", attrs={\"exception_type\": \"RuntimeError\"})\n\n levels = [message.level for message in transport.messages]\n assert levels == [\"DEBUG\", \"WARNING\", \"ERROR\", \"ERROR\"]", - "start_line": 262, - "end_line": 276, - "metadata": { - "chunk_index": 10, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "start_line": 169, - "end_line": 170, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/core/runtime.py", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "start_line": 18, - "end_line": 179, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceService", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "start_line": 39, - "end_line": 166, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step" - } - ], - "entrypoints": [], - "test_candidates": [ - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optiona" - }, - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n" - }, - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"in" - } - ], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optional-status\")\n manager.debug(\"debug without status\")\n manager.info(\"info without status\")\n manager.warning(\"warning without status\")\n manager.error(\"error without status\")\n\n assert [message.status for message in transport.messages] == [\"\", \"\", \"\", \"\"]\n assert all(message.trace_id == transport.contexts[0].trace_id for message in transport.messages)", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "span_start": 279, - "span_end": 293, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 11, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"parse\")\n manager.info(\"started\", status=\"ok\", attrs={\"attempt\": 1})\n\n assert len(transport.contexts) == 1\n assert len(transport.messages) == 1\n assert transport.contexts[0].alias == \"worker\"\n assert transport.messages[0].step == \"parse\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "span_start": 246, - "span_end": 259, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 9, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"validate\")\n manager.debug(\"validation details\", attrs={\"rule\": \"basic\"})\n manager.warning(\"validation warning\", status=\"degraded\", attrs={\"attempt\": 1})\n manager.error(\"integration failed\", status=\"failed\", attrs={\"integration\": \"crm\"})\n manager.exception(\"caught exception\", attrs={\"exception_type\": \"RuntimeError\"})\n\n levels = [message.level for message in transport.messages]\n assert levels == [\"DEBUG\", \"WARNING\", \"ERROR\", \"ERROR\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "span_start": 262, - "span_end": 276, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 10, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 24, - "C2_DEPENDENCY_GRAPH": 27, - "C0_SOURCE_CHUNKS": 11 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optional-status\")\n manager.debug(\"debug without status\")\n manager.info(\"info without status\")\n manager.warning(\"warning without status\")\n manager.error(\"error without status\")\n\n assert [message.status for message in transport.messages] == [\"\", \"\", \"\", \"\"]\n assert all(message.trace_id == transport.contexts[0].trace_id for message in transport.messages)", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "span_start": 279, - "span_end": 293, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 11, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"parse\")\n manager.info(\"started\", status=\"ok\", attrs={\"attempt\": 1})\n\n assert len(transport.contexts) == 1\n assert len(transport.messages) == 1\n assert transport.contexts[0].alias == \"worker\"\n assert transport.messages[0].step == \"parse\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "span_start": 246, - "span_end": 259, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 9, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"validate\")\n manager.debug(\"validation details\", attrs={\"rule\": \"basic\"})\n manager.warning(\"validation warning\", status=\"degraded\", attrs={\"attempt\": 1})\n manager.error(\"integration failed\", status=\"failed\", attrs={\"integration\": \"crm\"})\n manager.exception(\"caught exception\", attrs={\"exception_type\": \"RuntimeError\"})\n\n levels = [message.level for message in transport.messages]\n assert levels == [\"DEBUG\", \"WARNING\", \"ERROR\", \"ERROR\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "span_start": 262, - "span_end": 276, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 10, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md deleted file mode 100644 index 36b6727..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для TraceService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "tests/test_runtime.py:test_trace_service_allows_messages_without_status \ntests/test_runtime.py:test_trace_service_writes_contexts_and_messages \ntests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md deleted file mode 100644 index 8d465e3..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-workflow-runtime-factory-negative - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для WorkflowRuntimeFactory? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Insufficient evidence for a confident answer. No test candidates found.", - "answer_mode": "degraded", - "path_scope": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md deleted file mode 100644 index b301f23..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md +++ /dev/null @@ -1,31 +0,0 @@ -# plba-v2-open-file-nonexistent - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Открой файл src/app_runtime/core/missing_runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 0, - "llm_answer": "Файл `src/app_runtime/core/missing_runtime.py` не найден.", - "answer_mode": "not_found", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- answer_mode: expected degraded, got not_found -- llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json deleted file mode 100644 index d68abc5..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json +++ /dev/null @@ -1,419 +0,0 @@ -{ - "case_id": "plba-v2-open-file-public-api", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Открой файл src/plba/__init__.py", - "actual": { - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь к файлу: src/plba/__init__.py\n\nВ этом файле находятся импортированные модули и классы из различных подпакетов библиотеки plba. Файл служит точкой входа для пользователей, предоставляя доступ к основным функциям и классам библиотеки. В частности, здесь импортируются:\n\n- Функции и классы для создания runtime (create_runtime)\n- Конфигурационные файлы и провайдеры (ConfigFileLoader, FileConfigProvider)\n- Контрольные каналы и службы (ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel)\n- Определения контрактов (ApplicationModule, ConfigProvider, HealthContributor и др.)\n- Менеджеры конфигурации и выполнения (ConfigurationManager, RuntimeManager, ServiceContainer)\n- Службы мониторинга здоровья (HealthRegistry)\n- Управление логированием (LogManager)\n- Очереди задач (InMemoryTaskQueue)\n- Транспортировка трассировки (MySqlTraceTransport, NoOpTraceTransport, TraceService)\n- Определение рабочих потоков и контекстов (StepResult, WorkflowContext, WorkflowDefinition, Workf)", - "answer_mode": "answered", - "path_scope": [ - "src/plba/__init__.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "passed": false, - "mismatches": [ - "llm: expected answer to exclude 'из различных подпакетов'" - ], - "details": { - "query": "Открой файл src/plba/__init__.py", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Открой файл src/plba/__init__.py", - "normalized": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/plba/__init__.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/plba/__init__.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 32 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/plba/__init__.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/plba/__init__.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "not_requested", - "resolved_symbol": null, - "alternatives": [], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": false, - "require_flow": false, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "keyword_hints": [], - "symbol_candidates": [], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/plba/__init__.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/plba/__init__.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Открой файл src/plba/__init__.py", - "normalized": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/plba/__init__.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/plba/__init__.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 32 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [], - "resolved_symbol": null, - "symbol_resolution_status": "not_requested", - "file_candidates": [ - "src/plba/__init__.py" - ], - "code_chunks": [ - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 0, - "prefer_bonus": 0, - "test_penalty": 0, - "structural_rank": 0, - "layer_rank": 0, - "distance": 0, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C0_SOURCE_CHUNKS": "exact_path_fetch" - }, - "top_k_by_layer": { - "C0_SOURCE_CHUNKS": 200 - }, - "filters_by_layer": { - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/plba/__init__.py" - ] - } - }, - "requests": [ - { - "layer": "C0_SOURCE_CHUNKS", - "query": "Открой файл src/plba/__init__.py", - "ranking_profile": "code" - } - ], - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 20 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "layers": [ - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_requested" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 1 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 0, - "prefer_bonus": 0, - "test_penalty": 0, - "structural_rank": 0, - "layer_rank": 0, - "distance": 0, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md deleted file mode 100644 index ce42881..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md +++ /dev/null @@ -1,30 +0,0 @@ -# plba-v2-open-file-public-api - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Открой файл src/plba/__init__.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь к файлу: src/plba/__init__.py\n\nВ этом файле находятся импортированные модули и классы из различных подпакетов библиотеки plba. Файл служит точкой входа для пользователей, предоставляя доступ к основным функциям и классам библиотеки. В частности, здесь импортируются:\n\n- Функции и классы для создания runtime (create_runtime)\n- Конфигурационные файлы и провайдеры (ConfigFileLoader, FileConfigProvider)\n- Контрольные каналы и службы (ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel)\n- Определения контрактов (ApplicationModule, ConfigProvider, HealthContributor и др.)\n- Менеджеры конфигурации и выполнения (ConfigurationManager, RuntimeManager, ServiceContainer)\n- Службы мониторинга здоровья (HealthRegistry)\n- Управление логированием (LogManager)\n- Очереди задач (InMemoryTaskQueue)\n- Транспортировка трассировки (MySqlTraceTransport, NoOpTraceTransport, TraceService)\n- Определение рабочих потоков и контекстов (StepResult, WorkflowContext, WorkflowDefinition, Workf)", - "answer_mode": "answered", - "path_scope": [ - "src/plba/__init__.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- llm: expected answer to exclude 'из различных подпакетов' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md deleted file mode 100644 index b1b8431..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md +++ /dev/null @@ -1,30 +0,0 @@ -# plba-v2-open-file-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/app_runtime/core/runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь: src/app_runtime/core/runtime.py\n\nВ этом файле содержится определение класса `RuntimeManager`. В примере приведено начало класса с инициализатором (`__init__`) и некоторыми атрибутами и параметрами, такими как `ACTION_TIMEOUT_SECONDS`, `ACTION_POLL_INTERVAL_SECONDS`, а также параметрами конфигурации и сервисов, которые могут передаваться при создании экземпляра класса.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json deleted file mode 100644 index d10f193..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json +++ /dev/null @@ -1,4707 +0,0 @@ -{ - "case_id": "plba-v2-trace-flow-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "actual": { - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. HttpControlAppFactory.create(health_provider, action_provider)\n - Создает экземпляр FastAPI приложения.\n - Добавляет middleware для логирования времени ответа.\n - Определяет маршрут `/health`.\n \n2. HttpControlAppFactory.create().get(\"/health\")\n - Вызывает health_provider, чтобы получить состояние здоровья.\n - Устанавливает статус-код ответа:\n - 200, если состояние \"ok\".\n - 503, если состояние отличное от \"ok\".\n - Возвращает JSON с состоянием здоровья.\n\nЦепочка неполная, так как отсутствует детальная информация о вызове health_provider и его реализации.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Покажи как проходит запрос /health в HttpControlAppFactory", - "normalized": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "negations": [], - "expansions": [ - "health", - "HttpControlAppFactory" - ], - "keyword_hints": [ - "health", - "HttpControlAppFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "SYMBOL", - "value": "health", - "source": "user_text", - "subtype": null, - "span": { - "start": 28, - "end": 34 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "HttpControlAppFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 37, - "end": 58 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 10 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "health", - "HttpControlAppFactory" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "keyword_hints": [ - "health", - "HttpControlAppFactory" - ], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 10 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Покажи как проходит запрос /health в HttpControlAppFactory", - "normalized": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "negations": [], - "expansions": [ - "health", - "HttpControlAppFactory" - ], - "keyword_hints": [ - "health", - "HttpControlAppFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "SYMBOL", - "value": "health", - "source": "user_text", - "subtype": null, - "span": { - "start": 28, - "end": 34 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "HttpControlAppFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 37, - "end": 58 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "HttpControlAppFactory", - "ControlActionSet", - "ControlPlaneService", - "HealthContributor.health", - "HealthContributor", - "ControlChannel" - ], - "resolved_symbol": "HttpControlAppFactory", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/contracts/health.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/service.py", - "src/app_runtime/health/registry.py", - "src/app_runtime/core/types.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "class HttpControlAppFactory\nHttpControlAppFactory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "qname": "HttpControlAppFactory", - "kind": "class", - "signature": "HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlAppFactory", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "start_line": 8, - "end_line": 8, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "class ControlActionSet\nControlActionSet", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/contracts/health.py", - "title": "HealthContributor.health", - "content": "method HealthContributor.health\nhealth(self)\nReturn contributor health state.", - "start_line": 9, - "end_line": 10, - "metadata": { - "symbol_id": "728cff18958d8a25e2661a0f08c83d68c3bbbfa8cef212b85dc0da2b11b3dc90", - "qname": "HealthContributor.health", - "kind": "method", - "signature": "health(self)", - "parent_symbol_id": "HealthContributor", - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/contracts/health.py", - "title": "HealthContributor", - "content": "class HealthContributor\nHealthContributor(ABC)", - "start_line": 7, - "end_line": 10, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "qname": "HealthContributor", - "kind": "class", - "signature": "HealthContributor(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/health.py", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/health/registry.py", - "title": "HealthRegistry", - "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)", - "start_line": 8, - "end_line": 56, - "metadata": { - "symbol_id": "fd3390eb0ba29c9979466b9c2117238e0da3bb829eeb4d505cb34c9c3df7a8e8", - "symbol_name": "HealthRegistry", - "qname": "HealthRegistry", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 2, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/core/types.py", - "title": "HealthPayload", - "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 7, - "end_line": 11, - "metadata": { - "symbol_id": "392235d63ddf752d6e419cb8528c93fe070d1bc02d3c87ba6a897baac810cf5d", - "symbol_name": "HealthPayload", - "qname": "HealthPayload", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "448a02e4a432b5ab65b246b2bd24a32a6f127b9d2091ea73b53ee3c0a2f53bb3", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/contracts/health.py", - "title": "HealthContributor", - "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 7, - "end_line": 10, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "symbol_name": "HealthContributor", - "qname": "HealthContributor", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/health/registry.py", - "title": "HealthRegistry.__init__:dataflow_slice", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register", - "start_line": 10, - "end_line": 13, - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/health/registry.py", - "title": "HealthRegistry.__init__:dataflow_slice", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths", - "start_line": 10, - "end_line": 16, - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory.create:calls", - "content": "HttpControlAppFactory.create calls time.monotonic", - "start_line": 25, - "end_line": 25, - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory.create:calls", - "content": "HttpControlAppFactory.create calls app.post", - "start_line": 37, - "end_line": 37, - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory.create:calls", - "content": "HttpControlAppFactory.create calls str", - "start_line": 27, - "end_line": 27, - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/health/registry.py", - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/health/registry.py", - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/http_app.py", - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlAppFactory.create calls time.monotonic" - }, - { - "path": "src/app_runtime/control/http_app.py", - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlAppFactory.create calls app.post" - }, - { - "path": "src/app_runtime/control/http_app.py", - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlAppFactory.create calls str" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory\nHttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "qname": "HttpControlAppFactory", - "kind": "class", - "signature": "HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 8, - "span_end": 8, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "method HealthContributor.health\nhealth(self)\nReturn contributor health state.", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor.health", - "span_start": 9, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "728cff18958d8a25e2661a0f08c83d68c3bbbfa8cef212b85dc0da2b11b3dc90", - "qname": "HealthContributor.health", - "kind": "method", - "signature": "health(self)", - "parent_symbol_id": "HealthContributor", - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor\nHealthContributor(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "qname": "HealthContributor", - "kind": "class", - "signature": "HealthContributor(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthRegistry", - "span_start": 8, - "span_end": 56, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 29, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd3390eb0ba29c9979466b9c2117238e0da3bb829eeb4d505cb34c9c3df7a8e8", - "symbol_name": "HealthRegistry", - "qname": "HealthRegistry", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 2, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/types.py", - "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthPayload", - "span_start": 7, - "span_end": 11, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "392235d63ddf752d6e419cb8528c93fe070d1bc02d3c87ba6a897baac810cf5d", - "symbol_name": "HealthPayload", - "qname": "HealthPayload", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "448a02e4a432b5ab65b246b2bd24a32a6f127b9d2091ea73b53ee3c0a2f53bb3", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "symbol_name": "HealthContributor", - "qname": "HealthContributor", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 13, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls time.monotonic", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 25, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls app.post", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 37, - "span_end": 37, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls str", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 27, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 10, - "C3_ENTRYPOINTS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 29, - "C0_SOURCE_CHUNKS": 16, - "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 53, - "C3_ENTRYPOINTS": 11 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 37 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory\nHttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "qname": "HttpControlAppFactory", - "kind": "class", - "signature": "HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 8, - "span_end": 8, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "method HealthContributor.health\nhealth(self)\nReturn contributor health state.", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor.health", - "span_start": 9, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "728cff18958d8a25e2661a0f08c83d68c3bbbfa8cef212b85dc0da2b11b3dc90", - "qname": "HealthContributor.health", - "kind": "method", - "signature": "health(self)", - "parent_symbol_id": "HealthContributor", - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor\nHealthContributor(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "qname": "HealthContributor", - "kind": "class", - "signature": "HealthContributor(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthRegistry", - "span_start": 8, - "span_end": 56, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 29, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd3390eb0ba29c9979466b9c2117238e0da3bb829eeb4d505cb34c9c3df7a8e8", - "symbol_name": "HealthRegistry", - "qname": "HealthRegistry", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 2, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/types.py", - "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthPayload", - "span_start": 7, - "span_end": 11, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "392235d63ddf752d6e419cb8528c93fe070d1bc02d3c87ba6a897baac810cf5d", - "symbol_name": "HealthPayload", - "qname": "HealthPayload", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "448a02e4a432b5ab65b246b2bd24a32a6f127b9d2091ea73b53ee3c0a2f53bb3", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "symbol_name": "HealthContributor", - "qname": "HealthContributor", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 13, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls time.monotonic", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 25, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls app.post", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 37, - "span_end": 37, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls str", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 27, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md deleted file mode 100644 index bfb4301..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md +++ /dev/null @@ -1,35 +0,0 @@ -# plba-v2-trace-flow-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи как проходит запрос /health в HttpControlAppFactory - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. HttpControlAppFactory.create(health_provider, action_provider)\n - Создает экземпляр FastAPI приложения.\n - Добавляет middleware для логирования времени ответа.\n - Определяет маршрут `/health`.\n \n2. HttpControlAppFactory.create().get(\"/health\")\n - Вызывает health_provider, чтобы получить состояние здоровья.\n - Устанавливает статус-код ответа:\n - 200, если состояние \"ok\".\n - 503, если состояние отличное от \"ok\".\n - Возвращает JSON с состоянием здоровья.\n\nЦепочка неполная, так как отсутствует детальная информация о вызове health_provider и его реализации.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json deleted file mode 100644 index 46b4f8b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json +++ /dev/null @@ -1,4868 +0,0 @@ -{ - "case_id": "plba-v2-trace-flow-runtime-start", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Покажи поток выполнения при запуске RuntimeManager", - "actual": { - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. Запускается `RuntimeManager` через инициализацию переменной `RuntimeManager`.\n2. Инициализация `RuntimeManager` вызывает метод `RuntimeManager.__init__`.\n3. В методе `RuntimeManager.__init__` происходит регистрация основных сервисов с помощью метода `_register_core_services`.\n4. Метод `_register_core_services` вызывает регистрацию базовых сервисов, таких как конфигурация (`configuration`), сервисы (`services`) и другие компоненты системы.\n5. Далее выполняется метод `start`, который инициирует запуск различных каналов управления и контрольных служб.\n6. Вызывается метод `ControlPlaneService.start`, передавая экземпляр `RuntimeManager`.\n7. Внутри `ControlPlaneService.start` регистрируется канал управления и запускается асинхронный процесс старта с использованием `asyncio.run`.\n8. Контрольный канал (`ControlChannel`) начинает свою работу путем вызова метода `start` и регистрации действий (`ControlActionSet`).\n9. Затем управление передается в HTTP-контроллер, где создается экземпляр `HttpControlChannel`, запускающий веб-сервер с помощью библиотеки Uvicorn.\n10. Веб-сервер принимает запросы на стандартные действия, такие как проверка состояния здоровья (`health`), выполнение стартовых и остановочных операций, получение статусов активности.\n\nЦепочка неполная, так как отсутствует детальная информация о внутренних взаимодействиях между сервисами и модулями после запуска основного канала управления.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Покажи поток выполнения при запуске RuntimeManager", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Покажи поток выполнения при запуске RuntimeManager", - "normalized": "Покажи поток выполнения при запуске RuntimeManager", - "sub_intent": "TRACE_FLOW", - "negations": [], - "expansions": [ - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 36, - "end": 50 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 10 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи поток выполнения при запуске RuntimeManager", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "keyword_hints": [ - "RuntimeManager" - ], - "symbol_candidates": [ - "RuntimeManager" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 10 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Покажи поток выполнения при запуске RuntimeManager", - "normalized": "Покажи поток выполнения при запуске RuntimeManager", - "sub_intent": "TRACE_FLOW", - "negations": [], - "expansions": [ - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 36, - "end": 50 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "RuntimeManager", - "ControlPlaneService", - "ControlChannel.start", - "ControlChannel.stop" - ], - "resolved_symbol": "RuntimeManager", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/bootstrap.py", - "src/app_runtime/control/service.py", - "src/app_runtime/core/runtime.py", - "src/plba/__init__.py", - "src/plba/core.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_channel.py", - "src/plba/control.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/service.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 9, - "end_line": 9, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "class RuntimeManager\nRuntimeManager", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "start_line": 16, - "end_line": 16, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/core.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.start", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "start_line": 23, - "end_line": 24, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.stop", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "start_line": 27, - "end_line": 28, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/control.py", - "title": "src/plba/control.py:1-10", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "start_line": 1, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "start_line": 32, - "end_line": 52, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager.__init__", - "start_line": 33, - "end_line": 39, - "metadata": { - "edge_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "dst_ref": "RuntimeManager.__init__", - "resolution": "resolved", - "slice_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager.__init__" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start", - "start_line": 32, - "end_line": 59, - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services", - "start_line": 32, - "end_line": 127, - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager._register_core_services", - "start_line": 33, - "end_line": 127, - "metadata": { - "edge_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "dst_ref": "RuntimeManager.__init__", - "resolution": "resolved", - "slice_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager.__init__" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager.__init__" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager._register_core_services" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "layer": "C4_SEMANTIC_ROLES", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 43, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 33, - "span_end": 39, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "dst_ref": "RuntimeManager.__init__", - "resolution": "resolved", - "slice_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager.__init__" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 59, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 127, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager._register_core_services", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 33, - "span_end": 127, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 10, - "C3_ENTRYPOINTS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 35, - "C0_SOURCE_CHUNKS": 14, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 52, - "C3_ENTRYPOINTS": 10 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи поток выполнения при запуске RuntimeManager", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 37 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "layer": "C4_SEMANTIC_ROLES", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 43, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 33, - "span_end": 39, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "dst_ref": "RuntimeManager.__init__", - "resolution": "resolved", - "slice_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager.__init__" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 59, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 127, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager._register_core_services", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 33, - "span_end": 127, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.services", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md deleted file mode 100644 index a84364c..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-trace-flow-runtime-start - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи поток выполнения при запуске RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. Запускается `RuntimeManager` через инициализацию переменной `RuntimeManager`.\n2. Инициализация `RuntimeManager` вызывает метод `RuntimeManager.__init__`.\n3. В методе `RuntimeManager.__init__` происходит регистрация основных сервисов с помощью метода `_register_core_services`.\n4. Метод `_register_core_services` вызывает регистрацию базовых сервисов, таких как конфигурация (`configuration`), сервисы (`services`) и другие компоненты системы.\n5. Далее выполняется метод `start`, который инициирует запуск различных каналов управления и контрольных служб.\n6. Вызывается метод `ControlPlaneService.start`, передавая экземпляр `RuntimeManager`.\n7. Внутри `ControlPlaneService.start` регистрируется канал управления и запускается асинхронный процесс старта с использованием `asyncio.run`.\n8. Контрольный канал (`ControlChannel`) начинает свою работу путем вызова метода `start` и регистрации действий (`ControlActionSet`).\n9. Затем управление передается в HTTP-контроллер, где создается экземпляр `HttpControlChannel`, запускающий веб-сервер с помощью библиотеки Uvicorn.\n10. Веб-сервер принимает запросы на стандартные действия, такие как проверка состояния здоровья (`health`), выполнение стартовых и остановочных операций, получение статусов активности.\n\nЦепочка неполная, так как отсутствует детальная информация о внутренних взаимодействиях между сервисами и модулями после запуска основного канала управления.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/summary.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/summary.md deleted file mode 100644 index 38cde5a..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/summary.md +++ /dev/null @@ -1,86 +0,0 @@ -# pipeline_setup_v3 summary - -Passed: 14/18 - -| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | -|------|------|------|-------|-------------------|------------|------| -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-control-plane | full_chain | Какие компоненты участвуют в ControlPlaneService? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-create-runtime | full_chain | Что делает функция create_runtime? | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-trace-service | full_chain | Объясни как работает класс TraceService | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-control-plane | full_chain | Найди точки входа HTTP control plane | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-create-runtime | full_chain | Где тесты для create_runtime? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-trace-service | full_chain | Где тесты для TraceService? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-workflow-runtime-factory-negative | full_chain | Где тесты для WorkflowRuntimeFactory? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-public-api | full_chain | Открой файл src/plba/__init__.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-health-endpoint | full_chain | Покажи как проходит запрос /health в HttpControlAppFactory | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | - -## Failures -- **plba-v2-explain-nonexistent-symbol**: answer_mode: expected degraded, got answered; retrieval: expected empty rag, got 33 rows; llm: expected answer to contain 'не найдена' -- **plba-v2-find-entrypoints-health-endpoint**: llm: expected answer to contain 'GET /health' -- **plba-v2-open-file-nonexistent**: answer_mode: expected degraded, got not_found; llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.' -- **plba-v2-open-file-public-api**: llm: expected answer to exclude 'из различных подпакетов' - -## LLM Answers -- **plba-v2-architecture-control-plane** - Query: Какие компоненты участвуют в ControlPlaneService? - > Подтвержденные связи и роли компонентов в контексте ControlPlaneService: \#\#\# Компоненты и их роли 1. \*\*ControlPlaneService\*\* \- Роль: pipeline\_stage \- Описание: Инициализирует каналы управления и управляет ими. 2. \*\*ControlChannel\*\* \- Роль: model \- Описание: Абстрактный класс для каналов управления с методами старта и остановки. 3. \*\*ControlActionSet\*\* \- Роль: model \- Описание: Представляет набор действий контроля. 4. \*\*UvicornThreadRunner\*\* \- Роль: pipeline\_stage \- Описание: Управляет uvicorn сервером и участвует в потоках данных. 5. \*\*HttpControlChannel\*\* \- Роль: pipeline\_stage \- Описание: Канал управления HTTP\-соединениями, участвующий в потоках данных. 6. \*\*HttpControlAppFactory\*\* \- Роль: factory \- Описание: Фабрика для создания fastAPI приложений. 7. \*\*WorkflowPersistence\*\* \- Роль: pipeline\_stage \- Описание: Хранит информацию о процессах и взаимодействует с ними.… -- **plba-v2-architecture-runtime-manager** - Query: Какие компоненты участвуют в RuntimeManager? - > \#\#\# Компоненты, участвующие в RuntimeManager \#\#\#\# Подтвержденные связи 1. \*\*RuntimeManager\*\* \- Role: Pipeline Stage \- Responsibilities: \- Manager responsibilities \- Orchestration of role\-like calls \- State attribute reading/writing \- Participation in dataflow slices 2. \*\*ControlPlaneService\*\* \- Role: Pipeline Stage \- Responsibilities: \- Service responsibilities \- State attribute reading/writing \- Participation in dataflow slices 3. \*\*UvicornThreadRunner\*\* \- Role: Pipeline Stage \- Responsibilities: \- State attribute reading/writing \- Participation in dataflow slices 4. \*\*HttpControlChannel\*\* \- Role: Pipeline Stage \- Responsibilities: \- State attribute reading/writing \- Participation in dataflow slices 5. \*\*WorkflowPersistence\*\* \- Role: Pipeline Stage \- Responsibilities: \- Orchestration of role\-like calls \- State attribute reading/writing \- Participation in dataflow sl… -- **plba-v2-explain-create-runtime** - Query: Что делает функция create_runtime? - > Функция \`create\_runtime\` инициализирует и настраивает менеджер выполнения приложения. \*\*Ключевые шаги:\*\* 1. Инициализация менеджера выполнения \(\`RuntimeManager\(\)\`\). 2. Добавление конфигурационного файла, если указан путь \(\`add\_config\_file\`\). 3. Регистрация HTTP\-канала управления, если включен режим управления \(\`register\_channel\`\). 4. Регистрация модуля приложения в менеджере выполнения \(\`register\_module\`\). \*\*Опорные файлы:\*\* \- \`src/plba/bootstrap.py:8\-29\` Этот процесс позволяет настроить и запустить приложение с учетом заданных конфигураций и режимов управления. -- **plba-v2-explain-local-http-channel** - Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - > Класс \`HttpControlChannel\` предназначен для управления HTTP каналом контроля в приложении. \*\*Ключевые шаги его реализации:\*\* 1. Инициализация \(\`\_\_init\_\_\`\) – принимает параметры хоста, порта и тайм\-аута, создаёт внутренние объекты управления и инициализирует состояние канала. 2. Запуск \(\`start\`\) – запускает сервер с заданными действиями контроля, создавая приложение и вызывая runner для запуска сервера. 3. Остановка \(\`stop\`\) – останавливает запущенный сервер. 4. Свойство \`port\` – возвращает порт, используемый сервером. 5. Метод \`\_health\_response\` – генерирует ответ о состоянии здоровья системы \(здоров или нет\). Опорные файлы: \- \`src/app\_runtime/control/http\_channel.py:12\-57\` \(определение класса и методов\) \- \`src/app\_runtime/control/http\_channel.py:13\-17\` \(инициализация\) \- \`src/app\_runtime/control/http\_channel.py:19\-22\` \(запуск\) -- **plba-v2-explain-nonexistent-symbol** - Query: Объясни класс RuntimeFactoryManager - > Класс \`RuntimeFactoryManager\` не указан напрямую в предоставленном коде. Однако, судя по контексту и взаимосвязям между классами: \*\*Назначение класса:\*\* \- Управление фабрикой для создания экземпляров классов, связанных с управлением рабочим состоянием приложения. \*\*Ключевые шаги:\*\* 1. Инициализация фабрики. 2. Создание экземпляра соответствующего класса управления каналом \(\`ControlChannel\`\) или другого необходимого класса. 3. Регистрация созданных каналов в сервисе управления каналами. \*\*Опорные файлы:\*\* \- \`src/app\_runtime/control/base.py\`: Объявление абстрактного базового класса \`ControlChannel\`. \- \`src/app\_runtime/control/service.py\`: Реализация сервиса управления каналами, который регистрирует созданные каналы. \- \`src/app\_runtime/control/http\_channel.py\`: Определение канала HTTP, используемого для взаимодействия через HTTP\-протокол. Обратите внимание, что прямое о… -- **plba-v2-explain-runtime-manager** - Query: Объясни как работает класс RuntimeManager - > \*\*Класс \`RuntimeManager\`\*\* отвечает за управление жизненным циклом приложения и координацию различных компонентов системы. \#\#\# Ключевые шаги работы класса: 1. \*\*Инициализация конфигурации:\*\* Класс инициализирует начальные настройки приложения, включая загрузку конфигурационных файлов. 2. \*\*Регистрация каналов управления:\*\* Метод \`register\_channel\` позволяет зарегистрировать каналы управления, которые будут использоваться для взаимодействия с различными компонентами системы. 3. \*\*Запуск и остановка системы:\*\* Методы \`start\` и \`stop\` инициируют запуск и остановку всех зарегистрированных каналов управления, обеспечивая корректное завершение работы системы. 4. \*\*Сохранение состояния:\*\* Метод \`snapshot\` создает снимок текущего состояния системы, который может быть использован для восстановления или анализа состояния в будущем. \#\#\# Опорные файлы: \- \`src/app\_runtime/core/ru… -- **plba-v2-explain-trace-service** - Query: Объясни как работает класс TraceService - > \*\*Класс \`TraceService\`\*\* предназначен для управления контекстом трассировки в приложении. Его основные функции включают создание нового контекста трассировки, получение текущего идентификатора трассировки и закрытие контекста. \*\*Ключевые шаги работы класса:\*\* 1. \*\*Инициализация:\*\* При создании экземпляра \`TraceService\` задаются транспорт и хранилище контекста трассировки \(по умолчанию используются заглушки\). 2. \*\*Создание контекста:\*\* Метод \`create\_context\` создает новый контекст трассировки с заданными параметрами \(идентификатор, родительский идентификатор, тип и атрибуты\). Контекст сохраняется в хранилище. 3. \*\*Получение текущего идентификатора:\*\* Метод \`current\_trace\_id\` возвращает текущий идентификатор трассировки. 4. \*\*Открытие контекста:\*\* Метод \`open\_context\` открывает новый контекст трассировки. 5. \*\*Закрытие контекста:\*\* Метод \`close\_context\` завершает текущ… -- **plba-v2-find-entrypoints-control-plane** - Query: Найди точки входа HTTP control plane - > confirmed\_entrypoints: \- src/app\_runtime/control/http\_app.py:app.post \(line range: 38\-42\) \- src/app\_runtime/control/http\_app.py:app.get \(line range: 31\-34\) \- src/app\_runtime/control/http\_app.py:app.get \(line range: 38\-42\) -- **plba-v2-find-entrypoints-health-endpoint** - Query: Где health endpoint? - > health endpoint: \- src/app\_runtime/control/http\_app.py:38\-42 \(app.post\) \- src/app\_runtime/control/http\_app.py:31\-34 \(app.get\) -- **plba-v2-find-tests-create-runtime** - Query: Где тесты для create_runtime? - > \- tests/test\_runtime.py:342\-405 \(test\_public\_plba\_package\_exports\_runtime\_builder\_and\_worker\_contract\) -- **plba-v2-find-tests-runtime-manager** - Query: Где тесты для RuntimeManager? - > \- tests/test\_runtime.py:12\-12 \- tests/test\_business\_control\_actions.py:14\-14 -- **plba-v2-find-tests-trace-service** - Query: Где тесты для TraceService? - > tests/test\_runtime.py:test\_trace\_service\_allows\_messages\_without\_status tests/test\_runtime.py:test\_trace\_service\_writes\_contexts\_and\_messages tests/test\_runtime.py:test\_trace\_service\_supports\_debug\_warning\_and\_error\_levels -- **plba-v2-find-tests-workflow-runtime-factory-negative** - Query: Где тесты для WorkflowRuntimeFactory? - > Insufficient evidence for a confident answer. No test candidates found. -- **plba-v2-open-file-nonexistent** - Query: Открой файл src/app_runtime/core/missing_runtime.py - > Файл \`src/app\_runtime/core/missing\_runtime.py\` не найден. -- **plba-v2-open-file-public-api** - Query: Открой файл src/plba/__init__.py - > Путь к файлу: src/plba/\_\_init\_\_.py В этом файле находятся импортированные модули и классы из различных подпакетов библиотеки plba. Файл служит точкой входа для пользователей, предоставляя доступ к основным функциям и классам библиотеки. В частности, здесь импортируются: \- Функции и классы для создания runtime \(create\_runtime\) \- Конфигурационные файлы и провайдеры \(ConfigFileLoader, FileConfigProvider\) \- Контрольные каналы и службы \(ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\) \- Определения контрактов \(ApplicationModule, ConfigProvider, HealthContributor и др.\) \- Менеджеры конфигурации и выполнения \(ConfigurationManager, RuntimeManager, ServiceContainer\) \- Службы мониторинга здоровья \(HealthRegistry\) \- Управление логированием \(LogManager\) \- Очереди задач \(InMemoryTaskQueue\) \- Транспортировка трассировки \(MySqlTraceTransport, NoOpTraceTran… -- **plba-v2-open-file-runtime** - Query: Открой файл src/app_runtime/core/runtime.py - > Путь: src/app\_runtime/core/runtime.py В этом файле содержится определение класса \`RuntimeManager\`. В примере приведено начало класса с инициализатором \(\`\_\_init\_\_\`\) и некоторыми атрибутами и параметрами, такими как \`ACTION\_TIMEOUT\_SECONDS\`, \`ACTION\_POLL\_INTERVAL\_SECONDS\`, а также параметрами конфигурации и сервисов, которые могут передаваться при создании экземпляра класса. -- **plba-v2-trace-flow-health-endpoint** - Query: Покажи как проходит запрос /health в HttpControlAppFactory - > 1. HttpControlAppFactory.create\(health\_provider, action\_provider\) \- Создает экземпляр FastAPI приложения. \- Добавляет middleware для логирования времени ответа. \- Определяет маршрут \`/health\`. 2. HttpControlAppFactory.create\(\).get\("/health"\) \- Вызывает health\_provider, чтобы получить состояние здоровья. \- Устанавливает статус\-код ответа: \- 200, если состояние "ok". \- 503, если состояние отличное от "ok". \- Возвращает JSON с состоянием здоровья. Цепочка неполная, так как отсутствует детальная информация о вызове health\_provider и его реализации. -- **plba-v2-trace-flow-runtime-start** - Query: Покажи поток выполнения при запуске RuntimeManager - > 1. Запускается \`RuntimeManager\` через инициализацию переменной \`RuntimeManager\`. 2. Инициализация \`RuntimeManager\` вызывает метод \`RuntimeManager.\_\_init\_\_\`. 3. В методе \`RuntimeManager.\_\_init\_\_\` происходит регистрация основных сервисов с помощью метода \`\_register\_core\_services\`. 4. Метод \`\_register\_core\_services\` вызывает регистрацию базовых сервисов, таких как конфигурация \(\`configuration\`\), сервисы \(\`services\`\) и другие компоненты системы. 5. Далее выполняется метод \`start\`, который инициирует запуск различных каналов управления и контрольных служб. 6. Вызывается метод \`ControlPlaneService.start\`, передавая экземпляр \`RuntimeManager\`. 7. Внутри \`ControlPlaneService.start\` регистрируется канал управления и запускается асинхронный процесс старта с использованием \`asyncio.run\`. 8. Контрольный канал \(\`ControlChannel\`\) начинает свою работу путем вызова метода \`start\` и… \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json deleted file mode 100644 index 452c3ea..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json +++ /dev/null @@ -1,4171 +0,0 @@ -{ - "case_id": "plba-v2-architecture-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "### Подтвержденные Связи\n\n1. **ControlPlaneService**:\n - Вызывает методы инициализации (`_channels`, `_start_async`, `register_channel`, `start`, `stop`, `_stop_async`) [evidence: 16-20].\n \n2. **ControlPlaneService** взаимодействует с другими компонентами через методы регистрации каналов и запуска:\n - Регистрация канала (`register_channel`) использует атрибут `_channels` для хранения списка зарегистрированных каналов [evidence: 22].\n - Запуск сервиса использует метод `start`, который также обращается к атрибуту `_channels` [evidence: 23].\n\n### Роли Компонентов\n\n1. **ControlPlaneService**:\n - Pipeline stage: отвечает за чтение и запись состояния атрибутов, участвует в данных срезах (dataflow slices).\n\n2. **ControlChannel**:\n - Model: выполняет функции модели управления каналами, включая запуск и остановку.\n\n3. **ControlActionSet**:\n - Default model role: обеспечивает стандартные действия для контроля.\n\n4. **UvicornThreadRunner**, **HttpControlChannel**, **HttpControlAppFactory**, **WorkflowPersistence**, **InMemoryTaskQueue**, **ConfigFileLoader**, **TraceContextStore**, **WorkerSupervisor**, **WorkflowEngine**:\n - Pipeline stages: отвечают за выполнение различных задач, связанных с обработкой данных и состоянием приложения.\n\n### Ограничения Контекста\n\nКонтекст ограничивается исключительно компонентами, связанными непосредственно с функциональностью ControlPlaneService и его методами. Другие компоненты и зависимости не рассматриваются в данном анализе.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Какие компоненты участвуют в ControlPlaneService?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Какие компоненты участвуют в ControlPlaneService?", - "normalized": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "negations": [], - "expansions": [ - "ControlPlaneService" - ], - "keyword_hints": [ - "ControlPlaneService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "ControlPlaneService", - "source": "user_text", - "subtype": null, - "span": { - "start": 29, - "end": 48 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 12 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 8 - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "ControlPlaneService" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "keyword_hints": [ - "ControlPlaneService" - ], - "symbol_candidates": [ - "ControlPlaneService" - ], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 12 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 8 - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Какие компоненты участвуют в ControlPlaneService?", - "normalized": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "negations": [], - "expansions": [ - "ControlPlaneService" - ], - "keyword_hints": [ - "ControlPlaneService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "ControlPlaneService", - "source": "user_text", - "subtype": null, - "span": { - "start": 29, - "end": 48 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "ControlPlaneService", - "ControlChannel" - ], - "resolved_symbol": "ControlPlaneService", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/app_runtime/control/service.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/http_app.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/workers/supervisor.py", - "src/app_runtime/workflow/engine/workflow_engine.py", - "src/app_runtime/core/runtime.py", - "src/plba/control.py", - "src/app_runtime/control/__init__.py", - "src/plba/__init__.py" - ], - "code_chunks": [ - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "title": "WorkflowEngine", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 86, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.start:calls", - "content": "ControlPlaneService.start calls asyncio.run", - "start_line": 22, - "end_line": 22, - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.register_channel:reads_attr", - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.start:reads_attr", - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels", - "start_line": 20, - "end_line": 20, - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "3030804d119fa1d4b8a6c32616062a5e11080b03d33818c9280bcc5bdd8fd512", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/control.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "bd7f620031a049b8d791534536941ce75071029542395a7bb14817742827070a", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "class ControlPlaneService\nControlPlaneService", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "qname": "ControlPlaneService", - "kind": "class", - "signature": "ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = plba.control.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "90b154d49d544efb7c448e91bf5b75231578a6571b98c06a2a555fa5dcffb152", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = plba.control.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.start calls asyncio.run" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start calls asyncio.run", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:calls", - "span_start": 22, - "span_end": 22, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:reads_attr", - "span_start": 20, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "3030804d119fa1d4b8a6c32616062a5e11080b03d33818c9280bcc5bdd8fd512", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bd7f620031a049b8d791534536941ce75071029542395a7bb14817742827070a", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService\nControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "qname": "ControlPlaneService", - "kind": "class", - "signature": "ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = plba.control.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "90b154d49d544efb7c448e91bf5b75231578a6571b98c06a2a555fa5dcffb152", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = plba.control.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C4_SEMANTIC_ROLES": "vector", - "C3_ENTRYPOINTS": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C4_SEMANTIC_ROLES": 12, - "C3_ENTRYPOINTS": 8, - "C2_DEPENDENCY_GRAPH": 8, - "C1_SYMBOL_CATALOG": 6, - "C0_SOURCE_CHUNKS": 4 - }, - "filters_by_layer": { - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 72, - "C3_ENTRYPOINTS": 39, - "C2_DEPENDENCY_GRAPH": 98, - "C1_SYMBOL_CATALOG": 40, - "C0_SOURCE_CHUNKS": 32 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start calls asyncio.run", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:calls", - "span_start": 22, - "span_end": 22, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:reads_attr", - "span_start": 20, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "3030804d119fa1d4b8a6c32616062a5e11080b03d33818c9280bcc5bdd8fd512", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bd7f620031a049b8d791534536941ce75071029542395a7bb14817742827070a", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService\nControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "qname": "ControlPlaneService", - "kind": "class", - "signature": "ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = plba.control.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "90b154d49d544efb7c448e91bf5b75231578a6571b98c06a2a555fa5dcffb152", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = plba.control.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md deleted file mode 100644 index cc320c0..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-architecture-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в ControlPlaneService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "### Подтвержденные Связи\n\n1. **ControlPlaneService**:\n - Вызывает методы инициализации (`_channels`, `_start_async`, `register_channel`, `start`, `stop`, `_stop_async`) [evidence: 16-20].\n \n2. **ControlPlaneService** взаимодействует с другими компонентами через методы регистрации каналов и запуска:\n - Регистрация канала (`register_channel`) использует атрибут `_channels` для хранения списка зарегистрированных каналов [evidence: 22].\n - Запуск сервиса использует метод `start`, который также обращается к атрибуту `_channels` [evidence: 23].\n\n### Роли Компонентов\n\n1. **ControlPlaneService**:\n - Pipeline stage: отвечает за чтение и запись состояния атрибутов, участвует в данных срезах (dataflow slices).\n\n2. **ControlChannel**:\n - Model: выполняет функции модели управления каналами, включая запуск и остановку.\n\n3. **ControlActionSet**:\n - Default model role: обеспечивает стандартные действия для контроля.\n\n4. **UvicornThreadRunner**, **HttpControlChannel**, **HttpControlAppFactory**, **WorkflowPersistence**, **InMemoryTaskQueue**, **ConfigFileLoader**, **TraceContextStore**, **WorkerSupervisor**, **WorkflowEngine**:\n - Pipeline stages: отвечают за выполнение различных задач, связанных с обработкой данных и состоянием приложения.\n\n### Ограничения Контекста\n\nКонтекст ограничивается исключительно компонентами, связанными непосредственно с функциональностью ControlPlaneService и его методами. Другие компоненты и зависимости не рассматриваются в данном анализе.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json deleted file mode 100644 index 4094a86..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json +++ /dev/null @@ -1,4363 +0,0 @@ -{ - "case_id": "plba-v2-architecture-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Какие компоненты участвуют в RuntimeManager?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "### Подтвержденные Связи\n\n1. **RuntimeManager**:\n - Является ключевым компонентом управления жизненным циклом приложения.\n - Инициализирует и управляет другими компонентами системы через метод `__init__`.\n \n2. **ControlPlaneService**:\n - Управляет каналами контроля.\n - Вызывается из метода инициализации `RuntimeManager` для регистрации каналов.\n\n3. **ControlChannel**:\n - Абстрактный класс для реализации конкретных каналов контроля.\n - Реализует методы `start` и `stop`, которые вызываются сервисами и менеджерами.\n\n4. **ConfigFileLoader**:\n - Загружает конфигурационные файлы и передает их в runtime-менеджер.\n\n5. **WorkflowPersistence**:\n - Обеспечивает сохранение информации о workflows.\n\n6. **InMemoryTaskQueue**:\n - Используется для хранения задач внутри памяти.\n\n7. **TraceContextStore**:\n - Хранит контекст трассировки.\n\n8. **WorkerSupervisor**:\n - Наблюдает за рабочими процессами и управляет ими.\n\n### Роли Компонентов\n\n1. **RuntimeManager**:\n - Координирует работу всех других компонентов.\n - Читает и записывает состояние атрибутов.\n - Участвует в управлении данными потока.\n\n2. **ControlPlaneService**:\n - Регистрирует каналы контроля.\n - Начинает и останавливает службы контроля.\n\n3. **ControlChannel**:\n - Осуществляет управление каналами взаимодействия между приложением и внешними системами.\n\n4. **ConfigFileLoader**:\n - Чтение конфигурации из файлов.\n\n5. **WorkflowPersistence**:\n - Сохраняет информацию о workflows.\n\n6. **InMemoryTaskQueue**:\n - Хранение данных задачи во временной памяти.\n\n7. **TraceContextStore**:\n - Управление контекстом трассировки.\n\n8. **WorkerSupervisor**:\n - Контроль рабочих процессов.\n\n### Ограничения Контекста\n\n1. **Dataflow Slices**:\n - Все перечисленные компоненты активно участвуют в обработке данных потоков.\n\n2. **State Attributes**:\n - Большинство компонентов читают или записывают состояние атрибутов системы.\n\nТаким образом, RuntimeManager является центральным управляющим элементом архитектуры, координирующим работу остальных компонентов.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Какие компоненты участвуют в RuntimeManager?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Какие компоненты участвуют в RuntimeManager?", - "normalized": "Какие компоненты участвуют в RuntimeManager?", - "sub_intent": "ARCHITECTURE", - "negations": [], - "expansions": [ - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 29, - "end": 43 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 12 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 8 - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в RuntimeManager?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "keyword_hints": [ - "RuntimeManager" - ], - "symbol_candidates": [ - "RuntimeManager" - ], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 12 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 8 - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Какие компоненты участвуют в RuntimeManager?", - "normalized": "Какие компоненты участвуют в RuntimeManager?", - "sub_intent": "ARCHITECTURE", - "negations": [], - "expansions": [ - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 29, - "end": 43 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "RuntimeManager", - "ControlChannel" - ], - "resolved_symbol": "RuntimeManager", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/app_runtime/core/runtime.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/service.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/http_app.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/workers/supervisor.py", - "src/plba/__init__.py", - "src/plba/core.py", - "src/plba/bootstrap.py", - "src/app_runtime/control/__init__.py" - ], - "code_chunks": [ - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start", - "start_line": 32, - "end_line": 59, - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "start_line": 32, - "end_line": 52, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services", - "start_line": 32, - "end_line": 127, - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "start_line": 16, - "end_line": 16, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/core.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/service.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 9, - "end_line": 9, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "class RuntimeManager\nRuntimeManager", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "layer": "C4_SEMANTIC_ROLES", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 43, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 59, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 127, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C4_SEMANTIC_ROLES": "vector", - "C3_ENTRYPOINTS": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C4_SEMANTIC_ROLES": 12, - "C3_ENTRYPOINTS": 8, - "C2_DEPENDENCY_GRAPH": 8, - "C1_SYMBOL_CATALOG": 6, - "C0_SOURCE_CHUNKS": 4 - }, - "filters_by_layer": { - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 28, - "C3_ENTRYPOINTS": 19, - "C2_DEPENDENCY_GRAPH": 54, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 15 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в RuntimeManager?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "layer": "C4_SEMANTIC_ROLES", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 43, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 59, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1", - "dst_ref": "RuntimeManager.start", - "resolution": "resolved", - "slice_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.start" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "77a7b260193018845e4e204df094ab89cfd7c82ee4e822b3a83ad4cd945f9cb1" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 127, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6", - "dst_ref": "RuntimeManager._register_core_services", - "resolution": "resolved", - "slice_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager._register_core_services" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "972d6057a6caac9cf31ebc1e29c6f39f71b10d4cc170dec57cf875ba458549c6" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md deleted file mode 100644 index 35c56ff..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-architecture-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в RuntimeManager? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "### Подтвержденные Связи\n\n1. **RuntimeManager**:\n - Является ключевым компонентом управления жизненным циклом приложения.\n - Инициализирует и управляет другими компонентами системы через метод `__init__`.\n \n2. **ControlPlaneService**:\n - Управляет каналами контроля.\n - Вызывается из метода инициализации `RuntimeManager` для регистрации каналов.\n\n3. **ControlChannel**:\n - Абстрактный класс для реализации конкретных каналов контроля.\n - Реализует методы `start` и `stop`, которые вызываются сервисами и менеджерами.\n\n4. **ConfigFileLoader**:\n - Загружает конфигурационные файлы и передает их в runtime-менеджер.\n\n5. **WorkflowPersistence**:\n - Обеспечивает сохранение информации о workflows.\n\n6. **InMemoryTaskQueue**:\n - Используется для хранения задач внутри памяти.\n\n7. **TraceContextStore**:\n - Хранит контекст трассировки.\n\n8. **WorkerSupervisor**:\n - Наблюдает за рабочими процессами и управляет ими.\n\n### Роли Компонентов\n\n1. **RuntimeManager**:\n - Координирует работу всех других компонентов.\n - Читает и записывает состояние атрибутов.\n - Участвует в управлении данными потока.\n\n2. **ControlPlaneService**:\n - Регистрирует каналы контроля.\n - Начинает и останавливает службы контроля.\n\n3. **ControlChannel**:\n - Осуществляет управление каналами взаимодействия между приложением и внешними системами.\n\n4. **ConfigFileLoader**:\n - Чтение конфигурации из файлов.\n\n5. **WorkflowPersistence**:\n - Сохраняет информацию о workflows.\n\n6. **InMemoryTaskQueue**:\n - Хранение данных задачи во временной памяти.\n\n7. **TraceContextStore**:\n - Управление контекстом трассировки.\n\n8. **WorkerSupervisor**:\n - Контроль рабочих процессов.\n\n### Ограничения Контекста\n\n1. **Dataflow Slices**:\n - Все перечисленные компоненты активно участвуют в обработке данных потоков.\n\n2. **State Attributes**:\n - Большинство компонентов читают или записывают состояние атрибутов системы.\n\nТаким образом, RuntimeManager является центральным управляющим элементом архитектуры, координирующим работу остальных компонентов.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json deleted file mode 100644 index 5296731..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json +++ /dev/null @@ -1,3779 +0,0 @@ -{ - "case_id": "plba-v2-explain-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Что делает функция create_runtime?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Функция `create_runtime` инициализирует и настраивает менеджер выполнения приложения.\n\n**Ключевые шаги:**\n1. Создает экземпляр менеджера выполнения (`RuntimeManager`).\n2. При наличии указанного пути к конфигурационному файлу добавляет его в менеджер.\n3. Если включена опция HTTP-контроля, регистрирует канал управления с указанными параметрами хоста, порта и тайм-аута.\n4. Регистрирует указанный модуль приложения в менеджере.\n5. Возвращает созданный менеджер выполнения.\n\n**Опорные файлы:**\n- `src/plba/bootstrap.py:8-29`", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Что делает функция create_runtime?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Что делает функция create_runtime?", - "normalized": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "function", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 19, - "end": 33 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "функция", - "source": "user_text", - "subtype": null, - "span": { - "start": 11, - "end": 18 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "create_runtime" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "create_runtime" - ], - "symbol_candidates": [ - "create_runtime" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Что делает функция create_runtime?", - "normalized": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "function", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 19, - "end": 33 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "функция", - "source": "user_text", - "subtype": null, - "span": { - "start": 11, - "end": 18 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "create_runtime", - "annotations", - "json", - "Path", - "Any", - "yaml", - "hashlib" - ], - "resolved_symbol": "create_runtime", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/plba/bootstrap.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/config/__init__.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/contracts/application.py", - "src/app_runtime/__init__.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/workers/supervisor.py", - "src/app_runtime/workflow/engine/workflow_engine.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/control/http_app.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "create_runtime", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "create_runtime", - "content": "function create_runtime\ncreate_runtime(module)", - "start_line": 8, - "end_line": 29, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "annotations", - "content": "const annotations\nannotations = __future__.annotations", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "json", - "content": "const json\nimport json", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Path", - "content": "const Path\nPath = pathlib.Path", - "start_line": 5, - "end_line": 5, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Any", - "content": "const Any\nAny = typing.Any", - "start_line": 6, - "end_line": 6, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "yaml", - "content": "const yaml\nimport yaml", - "start_line": 8, - "end_line": 8, - "metadata": { - "symbol_id": "223502bbfc2b82aea662f7466403cc99a3cd44f1b0507d637cd674874f751e4f", - "qname": "yaml", - "kind": "const", - "signature": "import yaml", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "hashlib", - "content": "const hashlib\nimport hashlib", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/bootstrap.py", - "title": "src/plba/bootstrap.py:create_runtime", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "start_line": 8, - "end_line": 29, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/__init__.py", - "title": "src/app_runtime/config/__init__.py:1-4", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/file_loader.py", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "start_line": 11, - "end_line": 48, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/application.py", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "start_line": 8, - "end_line": 16, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "title": "WorkflowEngine", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 86, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:instantiates", - "content": "create_runtime instantiates RuntimeManager", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.control_plane.register_channel", - "start_line": 21, - "end_line": 27, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.add_config_file" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime instantiates RuntimeManager" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.control_plane.register_channel" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.add_config_file" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const yaml\nimport yaml", - "layer": "C1_SYMBOL_CATALOG", - "title": "yaml", - "span_start": 8, - "span_end": 8, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "223502bbfc2b82aea662f7466403cc99a3cd44f1b0507d637cd674874f751e4f", - "qname": "yaml", - "kind": "const", - "signature": "import yaml", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 41, - "C0_SOURCE_CHUNKS": 21, - "C4_SEMANTIC_ROLES": 17, - "C2_DEPENDENCY_GRAPH": 46, - "C3_ENTRYPOINTS": 13 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const yaml\nimport yaml", - "layer": "C1_SYMBOL_CATALOG", - "title": "yaml", - "span_start": 8, - "span_end": 8, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "223502bbfc2b82aea662f7466403cc99a3cd44f1b0507d637cd674874f751e4f", - "qname": "yaml", - "kind": "const", - "signature": "import yaml", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md deleted file mode 100644 index b8c0d9e..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Что делает функция create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Функция `create_runtime` инициализирует и настраивает менеджер выполнения приложения.\n\n**Ключевые шаги:**\n1. Создает экземпляр менеджера выполнения (`RuntimeManager`).\n2. При наличии указанного пути к конфигурационному файлу добавляет его в менеджер.\n3. Если включена опция HTTP-контроля, регистрирует канал управления с указанными параметрами хоста, порта и тайм-аута.\n4. Регистрирует указанный модуль приложения в менеджере.\n5. Возвращает созданный менеджер выполнения.\n\n**Опорные файлы:**\n- `src/plba/bootstrap.py:8-29`", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md deleted file mode 100644 index eb88212..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-local-http-channel - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN_LOCAL", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` в файле `src/app_runtime/control/http_channel.py` реализует механизм управления HTTP-каналом для взаимодействия с внешними сервисами или компонентами.\n\n**Ключевые шаги его реализации:**\n1. Инициализация класса:\n - При создании экземпляра устанавливается таймаут (`_timeout`), запускается сервер через объект `UvicornThreadRunner`, создается фабрика приложений `HttpControlAppFactory`.\n \n2. Запуск канала:\n - Метод `start` инициализирует набор действий (`actions`) и создает приложение для работы с ними. Затем запускает сервер через ранее созданный объект `UvicornThreadRunner`.\n \n3. Остановка канала:\n - Метод `stop` останавливает запущенный сервер.\n\nОпорные файлы:\n- `src/app_runtime/control/http_channel.py`: определение и реализация класса `HttpControlChannel`.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "symbol_candidates": [ - "HttpControlChannel" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json deleted file mode 100644 index adca3b7..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json +++ /dev/null @@ -1,4092 +0,0 @@ -{ - "case_id": "plba-v2-explain-nonexistent-symbol", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Объясни класс RuntimeFactoryManager", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeFactoryManager` не найден в предоставленном коде или контекстной информации.\n\nКлючевые шаги и опорные файлы:\n1. Код и контекста относятся к управлению каналами управления («control channels») в приложении.\n2. Основные классы включают `ControlChannel`, `ControlActionSet`, и связанные с ними каналы и сервисы.\n3. Основной файл для рассмотрения — `base.py`.\n4. Ключевые обязанности и интерфейсы описаны через абстрактные методы (`start`, `stop`) в классе `ControlChannel`. \n\nПоскольку конкретный класс `RuntimeFactoryManager` отсутствует в данном контексте, невозможно предоставить его объяснение.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": false, - "mismatches": [ - "answer_mode: expected degraded, got answered", - "retrieval: expected empty rag, got 33 rows", - "llm: expected answer to contain 'не найдена'" - ], - "details": { - "query": "Объясни класс RuntimeFactoryManager", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Объясни класс RuntimeFactoryManager", - "normalized": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeFactoryManager" - ], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeFactoryManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 35 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 8, - "end": 13 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeFactoryManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Объясни класс RuntimeFactoryManager", - "normalized": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeFactoryManager" - ], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeFactoryManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 35 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 8, - "end": 13 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "ControlChannel", - "ControlChannel.stop", - "ControlActionSet", - "ControlPlaneService", - "ControlChannel.start" - ], - "resolved_symbol": null, - "symbol_resolution_status": "ambiguous", - "file_candidates": [ - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/service.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_app.py", - "src/plba/control.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/queue/in_memory.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "class ControlChannel\nControlChannel(ABC)", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.stop", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "start_line": 27, - "end_line": 28, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "class ControlActionSet\nControlActionSet", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.start", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "start_line": 23, - "end_line": 24, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/control.py", - "title": "src/plba/control.py:1-10", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "start_line": 1, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.register_channel:reads_attr", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.register_channel reads_attr self._channels.append" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel\nControlChannel(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 42, - "C0_SOURCE_CHUNKS": 20, - "C4_SEMANTIC_ROLES": 18, - "C2_DEPENDENCY_GRAPH": 54, - "C3_ENTRYPOINTS": 10 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel\nControlChannel(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md deleted file mode 100644 index 2908407..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md +++ /dev/null @@ -1,36 +0,0 @@ -# plba-v2-explain-nonexistent-symbol - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Объясни класс RuntimeFactoryManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeFactoryManager` не найден в предоставленном коде или контекстной информации.\n\nКлючевые шаги и опорные файлы:\n1. Код и контекста относятся к управлению каналами управления («control channels») в приложении.\n2. Основные классы включают `ControlChannel`, `ControlActionSet`, и связанные с ними каналы и сервисы.\n3. Основной файл для рассмотрения — `base.py`.\n4. Ключевые обязанности и интерфейсы описаны через абстрактные методы (`start`, `stop`) в классе `ControlChannel`. \n\nПоскольку конкретный класс `RuntimeFactoryManager` отсутствует в данном контексте, невозможно предоставить его объяснение.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- answer_mode: expected degraded, got answered -- retrieval: expected empty rag, got 33 rows -- llm: expected answer to contain 'не найдена' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md deleted file mode 100644 index 24ac750..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Объясни как работает класс RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeManager` играет ключевую роль в управлении выполнением приложений и координации различных компонентов системы. Его основная функция заключается в оркестрации действий, связанных с жизненным циклом приложения, включая инициализацию, запуск и остановку сервисов и модулей.\n\n**Ключевые шаги работы класса:**\n1. Инициализация конфигурации и состояния (`__init__`).\n2. Добавление конфигурационных файлов и настроек (`add_config_file`).\n3. Управление состоянием выполнения через чтение и запись атрибутов состояния (`configuration`, `_state`).\n4. Оркестровка вызова методов запуска и остановки для различных компонентов (`start`, `stop`).\n5. Участие в обработке данных потока и управлении потоками задач (`participates in dataflow slices`).\n\n**Опорные файлы:**\n- `src/app_runtime/core/runtime.py:18-179`\n- `src/app_runtime/control/service.py:12-52`\n- `src/app_runtime/control/base.py:21-28`\n- `src/app_runtime/control/base.py:14-18`", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json deleted file mode 100644 index 8b4c9d3..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json +++ /dev/null @@ -1,4157 +0,0 @@ -{ - "case_id": "plba-v2-explain-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Объясни как работает класс TraceService", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `TraceService` является основным компонентом системы отслеживания трассировок в приложении. Его основная функция заключается в управлении контекстом трассировки и записи событий в журнал.\n\n**Ключевые шаги работы класса:**\n1. Инициализация с передачей транспорта (`transport`) и хранилища контекста (`store`), которые могут быть опциональными.\n2. Создание нового контекста трассировки через метод `create_context`, который генерирует уникальный идентификатор трассы и сохраняет запись о контексте в хранилище.\n3. Управление текущим контекстом трассировки через методы:\n - `current_trace_id`: возвращает текущий идентификатор трассировки.\n - `open_context`: открывает новый контекст трассировки.\n - `close_context`: закрывает текущий контекст трассировки.\n \n**Опорные файлы:**\n- `src/app_runtime/tracing/service.py:39-166`\n- `src/app_runtime/tracing/service.py:66-78`\n- `src/app_runtime/tracing/service.py:45-63`", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Объясни как работает класс TraceService", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Объясни как работает класс TraceService", - "normalized": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 27, - "end": 39 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 21, - "end": 26 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "TraceService" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "TraceService" - ], - "symbol_candidates": [ - "TraceService" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Объясни как работает класс TraceService", - "normalized": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 27, - "end": 39 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 21, - "end": 26 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "TraceService", - "TraceService.open_context", - "TraceService.create_context", - "TraceService.current_trace_id" - ], - "resolved_symbol": "TraceService", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/app_runtime/core/runtime.py", - "src/app_runtime/tracing/__init__.py", - "src/app_runtime/tracing/service.py", - "src/plba/tracing.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/workers/supervisor.py", - "src/app_runtime/control/http_app.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "start_line": 20, - "end_line": 20, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 14, - "end_line": 14, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "start_line": 39, - "end_line": 166, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/tracing.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.open_context", - "content": "method TraceService.open_context\nopen_context(self)", - "start_line": 66, - "end_line": 78, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.create_context", - "content": "method TraceService.create_context\ncreate_context(self)", - "start_line": 45, - "end_line": 63, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.current_trace_id", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "start_line": 80, - "end_line": 81, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceService", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "start_line": 39, - "end_line": 166, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "start_line": 169, - "end_line": 170, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/core/runtime.py", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "start_line": 18, - "end_line": 179, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/__init__.py", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "start_line": 1, - "end_line": 17, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/tracing.py", - "title": "src/plba/tracing.py:1-4", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService", - "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)", - "start_line": 39, - "end_line": 166, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "symbol_name": "TraceService", - "qname": "TraceService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 13, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "start_line": 42, - "end_line": 61, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "start_line": 42, - "end_line": 84, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "start_line": 42, - "end_line": 78, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "start_line": 41, - "end_line": 43, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "start_line": 42, - "end_line": 81, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "start_line": 42, - "end_line": 88, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 60, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "symbol_name": "TraceService", - "qname": "TraceService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 13, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 38, - "C0_SOURCE_CHUNKS": 14, - "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 43, - "C3_ENTRYPOINTS": 9 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс TraceService", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 60, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "symbol_name": "TraceService", - "qname": "TraceService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 13, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md deleted file mode 100644 index 225c568..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Объясни как работает класс TraceService - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `TraceService` является основным компонентом системы отслеживания трассировок в приложении. Его основная функция заключается в управлении контекстом трассировки и записи событий в журнал.\n\n**Ключевые шаги работы класса:**\n1. Инициализация с передачей транспорта (`transport`) и хранилища контекста (`store`), которые могут быть опциональными.\n2. Создание нового контекста трассировки через метод `create_context`, который генерирует уникальный идентификатор трассы и сохраняет запись о контексте в хранилище.\n3. Управление текущим контекстом трассировки через методы:\n - `current_trace_id`: возвращает текущий идентификатор трассировки.\n - `open_context`: открывает новый контекст трассировки.\n - `close_context`: закрывает текущий контекст трассировки.\n \n**Опорные файлы:**\n- `src/app_runtime/tracing/service.py:39-166`\n- `src/app_runtime/tracing/service.py:66-78`\n- `src/app_runtime/tracing/service.py:45-63`", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md deleted file mode 100644 index 5287615..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md +++ /dev/null @@ -1,33 +0,0 @@ -# plba-v2-find-entrypoints-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Найди точки входа HTTP control plane - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Confirmed Entrypoints:\n1. src/app_runtime/control/http_app.py:app.post (lines 38-42)\n2. src/app_runtime/control/http_app.py:app.get (lines 31-34)\n3. src/app_runtime/control/http_app.py:app.get (lines 38-42)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md deleted file mode 100644 index 9dd7d51..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-entrypoints-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Где health endpoint? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "health endpoint: \n- src/app_runtime/control/http_app.py:38-42 (app.post)\n- src/app_runtime/control/http_app.py:31-34 (app.get)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "endpoint" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- llm: expected answer to contain 'GET /health' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json deleted file mode 100644 index 173bf33..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json +++ /dev/null @@ -1,2746 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для create_runtime?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:342-405", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для create_runtime?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для create_runtime?", - "normalized": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 28 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_create_runtime", - "Testcreate_runtime", - "create_runtime" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "create_runtime" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "create_runtime" - ], - "symbol_candidates": [ - "create_runtime" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_create_runtime", - "Testcreate_runtime", - "create_runtime" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для create_runtime?", - "normalized": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 28 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "create_runtime", - "FileConfigProvider", - "hashlib", - "json", - "Path", - "Any", - "annotations" - ], - "resolved_symbol": "create_runtime", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/plba/bootstrap.py", - "src/app_runtime/config/__init__.py", - "src/app_runtime/config/file_loader.py", - "tests/test_runtime.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/contracts/config.py", - "src/app_runtime/contracts/health.py", - "src/app_runtime/contracts/application.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "create_runtime", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "create_runtime", - "content": "function create_runtime\ncreate_runtime(module)", - "start_line": 8, - "end_line": 29, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/__init__.py", - "title": "FileConfigProvider", - "content": "const FileConfigProvider\nFileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "e449b19e5881889adeb6e056eafe1da30acbae864f06984ea2edc7c15f7cb6d6", - "qname": "FileConfigProvider", - "kind": "const", - "signature": "FileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "hashlib", - "content": "const hashlib\nimport hashlib", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "json", - "content": "const json\nimport json", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Path", - "content": "const Path\nPath = pathlib.Path", - "start_line": 5, - "end_line": 5, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Any", - "content": "const Any\nAny = typing.Any", - "start_line": 6, - "end_line": 6, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "annotations", - "content": "const annotations\nannotations = __future__.annotations", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:instantiates", - "content": "create_runtime instantiates RuntimeManager", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.control_plane.register_channel", - "start_line": 21, - "end_line": 27, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/bootstrap.py", - "title": "src/plba/bootstrap.py:create_runtime", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "start_line": 8, - "end_line": 29, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as PublicWorkerHealth\n from plba import WorkerStatus as PublicWorkerStatus\n from plba import create_runtime\n\n config_path = tmp_path / \"config.yml\"\n config_path.write_text(\"platform: {}\\n\", encoding=\"utf-8\")\n\n queue = InMemoryTaskQueue[int]()\n queue.put(2)\n assert queue.get(timeout=0.01) == 2\n queue.task_done()\n\n class PublicRoutine:\n def __init__(self) -> None:\n self.runs = 0\n\n def run(self) -> None:\n if self.runs == 0:\n self.runs += 1\n\n class PublicWorkerImpl(PublicWorker):\n def __init__(self, routine: PublicRoutine) -> None:\n self._inner = RoutineWorker(\"public-worker\", routine)\n\n @property\n def name(self) -> str:\n return self._inner.name\n\n @property\n def critical(self) -> bool:\n return self._inner.critical\n\n def start(self) -> None:\n self._inner.start()\n\n def stop(self, force: bool = False) -> None:\n self._inner.stop(force=force)\n\n def health(self) -> PublicWorkerHealth:\n return self._inner.health()\n\n def status(self) -> PublicWorkerStatus:\n return self._inner.status()\n\n class PublicExampleModule(PublicApplicationModule):\n @property\n def name(self) -> str:\n return \"public-example\"\n\n def register(self, registry: ModuleRegistry) -> None:\n registry.add_worker(PublicWorkerImpl(PublicRoutine()))\n\n runtime = create_runtime(PublicExampleModule(), config_path=str(config_path))\n runtime.start()\n sleep(0.2)\n assert runtime.configuration.get() == {\"platform\": {}}\n assert runtime.status()[\"workers\"][\"registered\"] == 1\n assert hasattr(plba, \"QueueWorker\") is False\n runtime.stop()", - "start_line": 342, - "end_line": 405, - "metadata": { - "chunk_index": 13, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/__init__.py", - "title": "src/app_runtime/config/__init__.py:1-4", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/file_loader.py", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "start_line": 11, - "end_line": 48, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/config.py", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/health.py", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/application.py", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "start_line": 8, - "end_line": 16, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.add_config_file" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime instantiates RuntimeManager" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.control_plane.register_channel" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.add_config_file" - } - ], - "entrypoints": [], - "test_candidates": [ - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as Public" - } - ], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "const FileConfigProvider\nFileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "layer": "C1_SYMBOL_CATALOG", - "title": "FileConfigProvider", - "span_start": 2, - "span_end": 2, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e449b19e5881889adeb6e056eafe1da30acbae864f06984ea2edc7c15f7cb6d6", - "qname": "FileConfigProvider", - "kind": "const", - "signature": "FileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as PublicWorkerHealth\n from plba import WorkerStatus as PublicWorkerStatus\n from plba import create_runtime\n\n config_path = tmp_path / \"config.yml\"\n config_path.write_text(\"platform: {}\\n\", encoding=\"utf-8\")\n\n queue = InMemoryTaskQueue[int]()\n queue.put(2)\n assert queue.get(timeout=0.01) == 2\n queue.task_done()\n\n class PublicRoutine:\n def __init__(self) -> None:\n self.runs = 0\n\n def run(self) -> None:\n if self.runs == 0:\n self.runs += 1\n\n class PublicWorkerImpl(PublicWorker):\n def __init__(self, routine: PublicRoutine) -> None:\n self._inner = RoutineWorker(\"public-worker\", routine)\n\n @property\n def name(self) -> str:\n return self._inner.name\n\n @property\n def critical(self) -> bool:\n return self._inner.critical\n\n def start(self) -> None:\n self._inner.start()\n\n def stop(self, force: bool = False) -> None:\n self._inner.stop(force=force)\n\n def health(self) -> PublicWorkerHealth:\n return self._inner.health()\n\n def status(self) -> PublicWorkerStatus:\n return self._inner.status()\n\n class PublicExampleModule(PublicApplicationModule):\n @property\n def name(self) -> str:\n return \"public-example\"\n\n def register(self, registry: ModuleRegistry) -> None:\n registry.add_worker(PublicWorkerImpl(PublicRoutine()))\n\n runtime = create_runtime(PublicExampleModule(), config_path=str(config_path))\n runtime.start()\n sleep(0.2)\n assert runtime.configuration.get() == {\"platform\": {}}\n assert runtime.status()[\"workers\"][\"registered\"] == 1\n assert hasattr(plba, \"QueueWorker\") is False\n runtime.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "span_start": 342, - "span_end": 405, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 13, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 32, - "C2_DEPENDENCY_GRAPH": 107, - "C0_SOURCE_CHUNKS": 684 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "const FileConfigProvider\nFileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "layer": "C1_SYMBOL_CATALOG", - "title": "FileConfigProvider", - "span_start": 2, - "span_end": 2, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e449b19e5881889adeb6e056eafe1da30acbae864f06984ea2edc7c15f7cb6d6", - "qname": "FileConfigProvider", - "kind": "const", - "signature": "FileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as PublicWorkerHealth\n from plba import WorkerStatus as PublicWorkerStatus\n from plba import create_runtime\n\n config_path = tmp_path / \"config.yml\"\n config_path.write_text(\"platform: {}\\n\", encoding=\"utf-8\")\n\n queue = InMemoryTaskQueue[int]()\n queue.put(2)\n assert queue.get(timeout=0.01) == 2\n queue.task_done()\n\n class PublicRoutine:\n def __init__(self) -> None:\n self.runs = 0\n\n def run(self) -> None:\n if self.runs == 0:\n self.runs += 1\n\n class PublicWorkerImpl(PublicWorker):\n def __init__(self, routine: PublicRoutine) -> None:\n self._inner = RoutineWorker(\"public-worker\", routine)\n\n @property\n def name(self) -> str:\n return self._inner.name\n\n @property\n def critical(self) -> bool:\n return self._inner.critical\n\n def start(self) -> None:\n self._inner.start()\n\n def stop(self, force: bool = False) -> None:\n self._inner.stop(force=force)\n\n def health(self) -> PublicWorkerHealth:\n return self._inner.health()\n\n def status(self) -> PublicWorkerStatus:\n return self._inner.status()\n\n class PublicExampleModule(PublicApplicationModule):\n @property\n def name(self) -> str:\n return \"public-example\"\n\n def register(self, registry: ModuleRegistry) -> None:\n registry.add_worker(PublicWorkerImpl(PublicRoutine()))\n\n runtime = create_runtime(PublicExampleModule(), config_path=str(config_path))\n runtime.start()\n sleep(0.2)\n assert runtime.configuration.get() == {\"platform\": {}}\n assert runtime.status()[\"workers\"][\"registered\"] == 1\n assert hasattr(plba, \"QueueWorker\") is False\n runtime.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "span_start": 342, - "span_end": 405, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 13, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md deleted file mode 100644 index a8ed71b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:342-405", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json deleted file mode 100644 index e4076db..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json +++ /dev/null @@ -1,3133 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для RuntimeManager?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:12-12\n- tests/test_business_control_actions.py:14-14", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для RuntimeManager?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для RuntimeManager?", - "normalized": "Где тесты для RuntimeManager?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 28 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_runtime_manager", - "TestRuntimeManager", - "RuntimeManager" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для RuntimeManager?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "RuntimeManager" - ], - "symbol_candidates": [ - "RuntimeManager" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_runtime_manager", - "TestRuntimeManager", - "RuntimeManager" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для RuntimeManager?", - "normalized": "Где тесты для RuntimeManager?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 28 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "RuntimeManager", - "ControlPlaneService" - ], - "resolved_symbol": "RuntimeManager", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/bootstrap.py", - "tests/test_runtime.py", - "src/app_runtime/core/runtime.py", - "src/plba/__init__.py", - "src/plba/core.py", - "tests/test_business_control_actions.py", - "src/app_runtime/control/service.py", - "src/app_runtime/control/__init__.py", - "src/plba/control.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/base.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "tests/test_runtime.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 12, - "end_line": 12, - "metadata": { - "symbol_id": "aeadc039653807b0da1ca6e3cc1078ee61cfc510b28e7f9c2ec04c59da43cc8d", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "class RuntimeManager\nRuntimeManager", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "start_line": 16, - "end_line": 16, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/core.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "tests/test_business_control_actions.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 14, - "end_line": 14, - "metadata": { - "symbol_id": "a1572ea8183dc0cd6ddbc74342bbde8c28cecfde37ad40b62feff09f8d103d11", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/service.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 9, - "end_line": 9, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "start_line": 32, - "end_line": 52, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/control.py", - "title": "src/plba/control.py:1-10", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "start_line": 1, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_business_control_actions.py", - "title": "tests/test_business_control_actions.py:IntervalRoutine", - "content": "class IntervalRoutine:\n calls: list[float] = field(default_factory=list)\n _lock: Lock = field(default_factory=Lock)\n\n def run(self) -> None:\n with self._lock:\n self.calls.append(monotonic())\n\n def wait_runs(self, count: int, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n with self._lock:\n if len(self.calls) >= count:\n return True\n sleep(0.01)\n return False\n\n def deltas(self) -> list[float]:\n with self._lock:\n return [self.calls[index + 1] - self.calls[index] for index in range(len(self.calls) - 1)]", - "start_line": 18, - "end_line": 37, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_business_control_actions.py", - "title": "tests/test_business_control_actions.py:BlockingRoutine", - "content": "class BlockingRoutine:\n def __init__(self, started: Event, release: Event) -> None:\n self._started = started\n self._release = release\n\n def run(self) -> None:\n self._started.set()\n self._release.wait(timeout=5.0)", - "start_line": 40, - "end_line": 47, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" - } - ], - "entrypoints": [], - "test_candidates": [ - { - "path": "tests/test_business_control_actions.py", - "title": "tests/test_business_control_actions.py:IntervalRoutine", - "content": "class IntervalRoutine:\n calls: list[float] = field(default_factory=list)\n _lock: Lock = field(default_factory=Lock)\n\n def run(self) -> None:\n with self._lock:\n self.calls.append(monotonic())\n\n def wait_runs(self, count: int, timeout: float) -> bool:\n deadline = m" - }, - { - "path": "tests/test_business_control_actions.py", - "title": "tests/test_business_control_actions.py:BlockingRoutine", - "content": "class BlockingRoutine:\n def __init__(self, started: Event, release: Event) -> None:\n self._started = started\n self._release = release\n\n def run(self) -> None:\n self._started.set()\n self._release.wait(timeout=5.0)" - } - ], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 12, - "span_end": 12, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "aeadc039653807b0da1ca6e3cc1078ee61cfc510b28e7f9c2ec04c59da43cc8d", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_business_control_actions.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "a1572ea8183dc0cd6ddbc74342bbde8c28cecfde37ad40b62feff09f8d103d11", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_business_control_actions.py", - "content": "class IntervalRoutine:\n calls: list[float] = field(default_factory=list)\n _lock: Lock = field(default_factory=Lock)\n\n def run(self) -> None:\n with self._lock:\n self.calls.append(monotonic())\n\n def wait_runs(self, count: int, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n with self._lock:\n if len(self.calls) >= count:\n return True\n sleep(0.01)\n return False\n\n def deltas(self) -> list[float]:\n with self._lock:\n return [self.calls[index + 1] - self.calls[index] for index in range(len(self.calls) - 1)]", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_business_control_actions.py:IntervalRoutine", - "span_start": 18, - "span_end": 37, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_business_control_actions.py", - "content": "class BlockingRoutine:\n def __init__(self, started: Event, release: Event) -> None:\n self._started = started\n self._release = release\n\n def run(self) -> None:\n self._started.set()\n self._release.wait(timeout=5.0)", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_business_control_actions.py:BlockingRoutine", - "span_start": 40, - "span_end": 47, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 53, - "C2_DEPENDENCY_GRAPH": 75, - "C0_SOURCE_CHUNKS": 35 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для RuntimeManager?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 12, - "span_end": 12, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "aeadc039653807b0da1ca6e3cc1078ee61cfc510b28e7f9c2ec04c59da43cc8d", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_business_control_actions.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "a1572ea8183dc0cd6ddbc74342bbde8c28cecfde37ad40b62feff09f8d103d11", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_business_control_actions.py", - "content": "class IntervalRoutine:\n calls: list[float] = field(default_factory=list)\n _lock: Lock = field(default_factory=Lock)\n\n def run(self) -> None:\n with self._lock:\n self.calls.append(monotonic())\n\n def wait_runs(self, count: int, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n with self._lock:\n if len(self.calls) >= count:\n return True\n sleep(0.01)\n return False\n\n def deltas(self) -> list[float]:\n with self._lock:\n return [self.calls[index + 1] - self.calls[index] for index in range(len(self.calls) - 1)]", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_business_control_actions.py:IntervalRoutine", - "span_start": 18, - "span_end": 37, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_business_control_actions.py", - "content": "class BlockingRoutine:\n def __init__(self, started: Event, release: Event) -> None:\n self._started = started\n self._release = release\n\n def run(self) -> None:\n self._started.set()\n self._release.wait(timeout=5.0)", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_business_control_actions.py:BlockingRoutine", - "span_start": 40, - "span_end": 47, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_business_control_actions", - "is_test": true, - "blob_sha": "4c599657dbef51b9d5cd4ec0cc4170ac79c5b1d6b9a5e80782a770274cc39e9f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md deleted file mode 100644 index 7f1badd..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для RuntimeManager? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:12-12\n- tests/test_business_control_actions.py:14-14", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json deleted file mode 100644 index bea3487..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json +++ /dev/null @@ -1,3134 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для TraceService?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:test_trace_service_allows_messages_without_status (line range: 279-293)\n- tests/test_runtime.py:test_trace_service_writes_contexts_and_messages (line range: 246-259)\n- tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels (line range: 262-276)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для TraceService?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для TraceService?", - "normalized": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 26 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_trace_service", - "TestTraceService", - "TraceService" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "TraceService" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "TraceService" - ], - "symbol_candidates": [ - "TraceService" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_trace_service", - "TestTraceService", - "TraceService" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для TraceService?", - "normalized": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "TraceService" - ], - "keyword_hints": [ - "TraceService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "TraceService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "TraceService", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 26 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "TraceService", - "TraceService.open_context", - "TraceService.create_context", - "TraceService.current_trace_id" - ], - "resolved_symbol": "TraceService", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/app_runtime/core/runtime.py", - "src/app_runtime/tracing/__init__.py", - "src/app_runtime/tracing/service.py", - "src/plba/tracing.py", - "tests/test_runtime.py", - "src/app_runtime/contracts/__init__.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "start_line": 20, - "end_line": 20, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 14, - "end_line": 14, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/__init__.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "start_line": 39, - "end_line": 166, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/tracing.py", - "title": "TraceService", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.open_context", - "content": "method TraceService.open_context\nopen_context(self)", - "start_line": 66, - "end_line": 78, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.create_context", - "content": "method TraceService.create_context\ncreate_context(self)", - "start_line": 45, - "end_line": 63, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.current_trace_id", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "start_line": 80, - "end_line": 81, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "start_line": 42, - "end_line": 61, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "start_line": 42, - "end_line": 84, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "start_line": 42, - "end_line": 78, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "start_line": 41, - "end_line": 43, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "start_line": 42, - "end_line": 81, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/tracing/service.py", - "title": "TraceService.__init__:dataflow_slice", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "start_line": 42, - "end_line": 88, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/tracing.py", - "title": "src/plba/tracing.py:1-4", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optional-status\")\n manager.debug(\"debug without status\")\n manager.info(\"info without status\")\n manager.warning(\"warning without status\")\n manager.error(\"error without status\")\n\n assert [message.status for message in transport.messages] == [\"\", \"\", \"\", \"\"]\n assert all(message.trace_id == transport.contexts[0].trace_id for message in transport.messages)", - "start_line": 279, - "end_line": 293, - "metadata": { - "chunk_index": 11, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/__init__.py", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "start_line": 1, - "end_line": 17, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"parse\")\n manager.info(\"started\", status=\"ok\", attrs={\"attempt\": 1})\n\n assert len(transport.contexts) == 1\n assert len(transport.messages) == 1\n assert transport.contexts[0].alias == \"worker\"\n assert transport.messages[0].step == \"parse\"", - "start_line": 246, - "end_line": 259, - "metadata": { - "chunk_index": 9, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"validate\")\n manager.debug(\"validation details\", attrs={\"rule\": \"basic\"})\n manager.warning(\"validation warning\", status=\"degraded\", attrs={\"attempt\": 1})\n manager.error(\"integration failed\", status=\"failed\", attrs={\"integration\": \"crm\"})\n manager.exception(\"caught exception\", attrs={\"exception_type\": \"RuntimeError\"})\n\n levels = [message.level for message in transport.messages]\n assert levels == [\"DEBUG\", \"WARNING\", \"ERROR\", \"ERROR\"]", - "start_line": 262, - "end_line": 276, - "metadata": { - "chunk_index": 10, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "start_line": 169, - "end_line": 170, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/core/runtime.py", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "start_line": 18, - "end_line": 179, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/tracing/service.py", - "title": "src/app_runtime/tracing/service.py:TraceService", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "start_line": 39, - "end_line": 166, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id" - }, - { - "path": "src/app_runtime/tracing/service.py", - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step" - } - ], - "entrypoints": [], - "test_candidates": [ - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optiona" - }, - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n" - }, - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"in" - } - ], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optional-status\")\n manager.debug(\"debug without status\")\n manager.info(\"info without status\")\n manager.warning(\"warning without status\")\n manager.error(\"error without status\")\n\n assert [message.status for message in transport.messages] == [\"\", \"\", \"\", \"\"]\n assert all(message.trace_id == transport.contexts[0].trace_id for message in transport.messages)", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "span_start": 279, - "span_end": 293, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 11, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"parse\")\n manager.info(\"started\", status=\"ok\", attrs={\"attempt\": 1})\n\n assert len(transport.contexts) == 1\n assert len(transport.messages) == 1\n assert transport.contexts[0].alias == \"worker\"\n assert transport.messages[0].step == \"parse\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "span_start": 246, - "span_end": 259, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 9, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"validate\")\n manager.debug(\"validation details\", attrs={\"rule\": \"basic\"})\n manager.warning(\"validation warning\", status=\"degraded\", attrs={\"attempt\": 1})\n manager.error(\"integration failed\", status=\"failed\", attrs={\"integration\": \"crm\"})\n manager.exception(\"caught exception\", attrs={\"exception_type\": \"RuntimeError\"})\n\n levels = [message.level for message in transport.messages]\n assert levels == [\"DEBUG\", \"WARNING\", \"ERROR\", \"ERROR\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "span_start": 262, - "span_end": 276, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 10, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 26, - "C2_DEPENDENCY_GRAPH": 67, - "C0_SOURCE_CHUNKS": 57 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const TraceService\nTraceService = plba.tracing.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 20, - "span_end": 20, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "259ec03b77b9387ea53f69c77af32791dd29adf6de617ba72dd3f839197342a1", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = plba.tracing.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 14, - "span_end": 14, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "3ccf6212fd7d9730f9df933e2ee7671b65bdae0520577e1a49c6432262842db6", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ecd2fab7fa9744b2adca84d3d213f7aadcb7e1da84b9c2764a4ab39c65282b11", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService\nTraceService(TraceContextFactory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "c2b2b976d99f2c600000b753731b26e0a69adcb4359398b93073590c5d5d04f4", - "qname": "TraceService", - "kind": "class", - "signature": "TraceService(TraceContextFactory)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "const TraceService\nTraceService = app_runtime.tracing.service.TraceService", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "a4556fb3f83c50ea68b94a679786ce802cab7ffd9d7138aad3d6009b2661f425", - "qname": "TraceService", - "kind": "const", - "signature": "TraceService = app_runtime.tracing.service.TraceService", - "parent_symbol_id": null, - "package_or_module": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.open_context\nopen_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.open_context", - "span_start": 66, - "span_end": 78, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "qname": "TraceService.open_context", - "kind": "method", - "signature": "open_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.create_context\ncreate_context(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.create_context", - "span_start": 45, - "span_end": 63, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "qname": "TraceService.create_context", - "kind": "method", - "signature": "create_context(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "method TraceService.current_trace_id\ncurrent_trace_id(self)", - "layer": "C1_SYMBOL_CATALOG", - "title": "TraceService.current_trace_id", - "span_start": 80, - "span_end": 81, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "qname": "TraceService.current_trace_id", - "kind": "method", - "signature": "current_trace_id(self)", - "parent_symbol_id": "TraceService", - "package_or_module": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.create_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 61, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a", - "dst_ref": "TraceService.create_context", - "resolution": "resolved", - "slice_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.create_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "ff44881104b65ef50ee6fe16d367d4a81b6e7eb5c44c0963cf4543faec785d4a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.close_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 84, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c", - "dst_ref": "TraceService.close_context", - "resolution": "resolved", - "slice_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.close_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "01e14158dcced7e52d0c8ac84ac7b9a75225c261b6aca6a1d7da802d0994721c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.open_context", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 78, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426", - "dst_ref": "TraceService.open_context", - "resolution": "resolved", - "slice_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.open_context" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "2da3d5b20a947bf63e14c103be4689b72fd837e0a82abd6c497846375d4c7426" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.transport\n -> TraceService.__init__", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 41, - "span_end": 43, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "dst_ref": "TraceService.__init__", - "resolution": "resolved", - "slice_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.transport", - "TraceService.__init__" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.current_trace_id", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 81, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c", - "dst_ref": "TraceService.current_trace_id", - "resolution": "resolved", - "slice_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.current_trace_id" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "41135180f7b3b9ab20e097e0747474e219c37dd2366ef08a7b43c1f3edb10b4c" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "TraceService.__init__:dataflow_slice", - "span_start": 42, - "span_end": 88, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "src_qname": "TraceService.__init__", - "dst_symbol_id": "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca", - "dst_ref": "TraceService.step", - "resolution": "resolved", - "slice_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", - "root_symbol_id": "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "path_symbols": [ - "TraceService.__init__", - "TraceService.store", - "TraceService.step" - ], - "path_symbol_ids": [ - "0e7c96d23b32da14ba3b30b3d0380c4832de8ed9986706d56d03e5111280ccfd", - "c44bfbc66cf747283f30088da3e011a10395031d41e77b74e523c24997f641ca" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/tracing.py", - "content": "from app_runtime.tracing.service import TraceService\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\"MySqlTraceTransport\", \"NoOpTraceTransport\", \"TraceService\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/tracing.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.tracing", - "is_test": false, - "blob_sha": "a27e11c716c93c3fcefe6f11b4cc420a6b743e7606606071d7f1aeeccc4e7d45", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_allows_messages_without_status() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\"):\n manager.step(\"optional-status\")\n manager.debug(\"debug without status\")\n manager.info(\"info without status\")\n manager.warning(\"warning without status\")\n manager.error(\"error without status\")\n\n assert [message.status for message in transport.messages] == [\"\", \"\", \"\", \"\"]\n assert all(message.trace_id == transport.contexts[0].trace_id for message in transport.messages)", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_allows_messages_without_status", - "span_start": 279, - "span_end": 293, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 11, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/__init__.py", - "content": "from app_runtime.contracts.trace import TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport\nfrom app_runtime.tracing.service import TraceManager, TraceService\nfrom app_runtime.tracing.store import ActiveTraceContext, TraceContextStore\nfrom app_runtime.tracing.transport import MySqlTraceTransport, NoOpTraceTransport\n\n__all__ = [\n \"ActiveTraceContext\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceContextStore\",\n \"TraceLogMessage\",\n \"TraceManager\",\n \"TraceService\",\n \"TraceTransport\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/__init__.py:1-17", - "span_start": 1, - "span_end": 17, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.tracing.__init__", - "is_test": false, - "blob_sha": "a01dea5f773515aeaae8e6d3431fcb93531a8b577dfa26c2e5db16cd6ae6e4d9", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_writes_contexts_and_messages() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"parse\")\n manager.info(\"started\", status=\"ok\", attrs={\"attempt\": 1})\n\n assert len(transport.contexts) == 1\n assert len(transport.messages) == 1\n assert transport.contexts[0].alias == \"worker\"\n assert transport.messages[0].step == \"parse\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_writes_contexts_and_messages", - "span_start": 246, - "span_end": 259, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 9, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_trace_service_supports_debug_warning_and_error_levels() -> None:\n from app_runtime.tracing.service import TraceService\n\n transport = RecordingTransport()\n manager = TraceService(transport=transport)\n\n with manager.open_context(alias=\"worker\", kind=\"worker\", attrs={\"routine\": \"incoming\"}):\n manager.step(\"validate\")\n manager.debug(\"validation details\", attrs={\"rule\": \"basic\"})\n manager.warning(\"validation warning\", status=\"degraded\", attrs={\"attempt\": 1})\n manager.error(\"integration failed\", status=\"failed\", attrs={\"integration\": \"crm\"})\n manager.exception(\"caught exception\", attrs={\"exception_type\": \"RuntimeError\"})\n\n levels = [message.level for message in transport.messages]\n assert levels == [\"DEBUG\", \"WARNING\", \"ERROR\", \"ERROR\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels", - "span_start": 262, - "span_end": 276, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 10, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceManager(TraceService):\n \"\"\"Compatibility alias during the transition from ConfigManager-shaped naming.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceManager", - "span_start": 169, - "span_end": 170, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 2, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/service.py", - "content": "class TraceService(TraceContextFactory):\n def __init__(self, transport: TraceTransport | None = None, store: TraceContextStore | None = None) -> None:\n self.transport = transport or NoOpTraceTransport()\n self.store = store or TraceContextStore()\n self._writer = TraceRecordWriter(self.transport)\n\n def create_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> str:\n record = TraceContextRecord(\n trace_id=uuid4().hex,\n alias=str(alias or \"\"),\n parent_id=parent_id,\n type=kind,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self.store.push(record)\n self._writer.write_context(record)\n return record.trace_id\n\n @contextmanager\n def open_context(\n self,\n *,\n alias: str,\n parent_id: str | None = None,\n kind: str | None = None,\n attrs: dict[str, Any] | None = None,\n ) -> Iterator[str]:\n trace_id = self.create_context(alias=alias, parent_id=parent_id, kind=kind, attrs=attrs)\n try:\n yield trace_id\n finally:\n self.store.pop()\n\n def current_trace_id(self) -> str | None:\n return self.store.current_trace_id()\n\n def close_context(self) -> str | None:\n previous = self.store.pop()\n return previous.record.trace_id if previous else None\n\n def step(self, name: str) -> None:\n self.store.set_step(str(name or \"\"))\n\n def info(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"INFO\", message, status, attrs)\n\n def debug(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"DEBUG\", message, status, attrs)\n\n def warning(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"WARNING\", message, status, attrs)\n\n def error(self, message: str, *, status: str | None = None, attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def exception(self, message: str, *, status: str = \"failed\", attrs: dict[str, Any] | None = None) -> None:\n self._write_message(\"ERROR\", message, status, attrs)\n\n def new_root(self, operation: str) -> TraceContext:\n trace_id = self.create_context(alias=operation, kind=\"operation\", attrs={\"operation\": operation})\n return TraceContext(trace_id=trace_id, span_id=trace_id, attributes={\"operation\": operation})\n\n def child_of(self, parent: TraceContext, operation: str) -> TraceContext:\n trace_id = self.create_context(\n alias=operation,\n parent_id=parent.trace_id,\n kind=\"worker\",\n attrs={\"operation\": operation},\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=trace_id,\n parent_span_id=parent.span_id,\n attributes={\"operation\": operation},\n )\n\n def attach(self, metadata: dict[str, object], context: TraceContext) -> dict[str, object]:\n updated = dict(metadata)\n updated[\"trace_id\"] = context.trace_id\n updated[\"span_id\"] = context.span_id\n updated[\"parent_span_id\"] = context.parent_span_id\n return updated\n\n def resume(self, metadata: dict[str, object], operation: str) -> TraceContext:\n trace_id = str(metadata.get(\"trace_id\") or uuid4().hex)\n span_id = str(metadata.get(\"span_id\") or trace_id)\n parent_id = metadata.get(\"parent_span_id\")\n self.create_context(\n alias=operation,\n parent_id=str(parent_id) if parent_id else None,\n kind=\"worker\",\n attrs=dict(metadata),\n )\n return TraceContext(\n trace_id=trace_id,\n span_id=span_id,\n parent_span_id=str(parent_id) if parent_id else None,\n attributes={\"operation\": operation},\n )\n\n def _write_message(\n self,\n level: TraceLevel,\n message: str,\n status: str | None,\n attrs: dict[str, Any] | None,\n ) -> None:\n active = self.store.current()\n if active is None:\n raise RuntimeError(\"Trace context is not bound. Call create_context() first.\")\n record = TraceLogMessage(\n trace_id=active.record.trace_id,\n step=active.step,\n status=str(status or \"\"),\n message=str(message or \"\"),\n level=level,\n event_time=utc_now(),\n attrs=dict(attrs or {}),\n )\n self._writer.write_message(record)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/tracing/service.py:TraceService", - "span_start": 39, - "span_end": 166, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.tracing.service", - "is_test": false, - "blob_sha": "87b875567583967acfa38996526d6e7592bffeb778de094fa4855aff8f8436d7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md deleted file mode 100644 index 15eb7ce..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для TraceService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:test_trace_service_allows_messages_without_status (line range: 279-293)\n- tests/test_runtime.py:test_trace_service_writes_contexts_and_messages (line range: 246-259)\n- tests/test_runtime.py:test_trace_service_supports_debug_warning_and_error_levels (line range: 262-276)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json deleted file mode 100644 index c6b7e33..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json +++ /dev/null @@ -1,3001 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-workflow-runtime-factory-negative", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для WorkflowRuntimeFactory?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Insufficient evidence for a confident answer. No test candidates found.", - "answer_mode": "degraded", - "path_scope": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для WorkflowRuntimeFactory?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для WorkflowRuntimeFactory?", - "normalized": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "WorkflowRuntimeFactory" - ], - "keyword_hints": [ - "WorkflowRuntimeFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "WorkflowRuntimeFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 36 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_workflow_runtime_factory", - "TestWorkflowRuntimeFactory", - "WorkflowRuntimeFactory" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "WorkflowRuntimeFactory" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "WorkflowRuntimeFactory" - ], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_workflow_runtime_factory", - "TestWorkflowRuntimeFactory", - "WorkflowRuntimeFactory" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для WorkflowRuntimeFactory?", - "normalized": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "WorkflowRuntimeFactory" - ], - "keyword_hints": [ - "WorkflowRuntimeFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "WorkflowRuntimeFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 36 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "WorkflowRuntimeFactory", - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory.create_engine", - "WorkflowPersistence", - "annotations", - "WorkflowEngine" - ], - "resolved_symbol": "WorkflowRuntimeFactory", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/app_runtime/workflow/runtime_factory.py", - "src/plba/workflow.py", - "src/app_runtime/config/__init__.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/contracts/config.py", - "src/app_runtime/contracts/health.py", - "src/app_runtime/contracts/application.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "WorkflowRuntimeFactory", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "start_line": 21, - "end_line": 30, - "metadata": { - "symbol_id": "cb7c73db05c2622aac89114bed1cddd1d567de21cfac5c53037c62b1074b25c9", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory", - "content": "class WorkflowRuntimeFactory\nWorkflowRuntimeFactory", - "start_line": 7, - "end_line": 19, - "metadata": { - "symbol_id": "9da827270329de64ebb426fadaaa5e35145e6666b92c6da186e08bf4b071f458", - "qname": "WorkflowRuntimeFactory", - "kind": "class", - "signature": "WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/workflow.py", - "title": "WorkflowRuntimeFactory", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "80865947d1ca709971efe9d68a9ee1f348c1c43d351bf4e1b4a5884d72985b6b", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__", - "content": "method WorkflowRuntimeFactory.__init__\n__init__(self, connection_factory)", - "start_line": 8, - "end_line": 12, - "metadata": { - "symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "qname": "WorkflowRuntimeFactory.__init__", - "kind": "method", - "signature": "__init__(self, connection_factory)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.create_engine", - "content": "method WorkflowRuntimeFactory.create_engine\ncreate_engine(self, workflow)", - "start_line": 14, - "end_line": 19, - "metadata": { - "symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "qname": "WorkflowRuntimeFactory.create_engine", - "kind": "method", - "signature": "create_engine(self, workflow)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowPersistence", - "content": "const WorkflowPersistence\nWorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "35693d37698e35079400b6a021d46209966ce469d9f77763d1c82d82ef4600b2", - "qname": "WorkflowPersistence", - "kind": "const", - "signature": "WorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "annotations", - "content": "const annotations\nannotations = __future__.annotations", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "e016ec68f9d15d52fe0505774229fafc705c1bf3dfda78845a3db9b032a4441d", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowEngine", - "content": "const WorkflowEngine\nWorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "da4aee8bc7d248177fbc4f892732c6eb08baa6d268c32921a217747143a99fe0", - "qname": "WorkflowEngine", - "kind": "const", - "signature": "WorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 11, - "end_line": 19, - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 12, - "end_line": 17, - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 9, - "end_line": 16, - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 10, - "end_line": 19, - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:writes_attr", - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer", - "start_line": 12, - "end_line": 12, - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.create_engine:calls", - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default", - "start_line": 15, - "end_line": 18, - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "src/app_runtime/workflow/runtime_factory.py:WorkflowRuntimeFactory", - "content": "class WorkflowRuntimeFactory:\n def __init__(self, connection_factory=None, *, traces, hooks=None, snapshot_sanitizer=None) -> None:\n self._connection_factory = connection_factory\n self._traces = traces\n self._hooks = hooks\n self._snapshot_sanitizer = snapshot_sanitizer\n\n def create_engine(self, workflow) -> WorkflowEngine:\n persistence = WorkflowPersistence.create_default(\n self._connection_factory,\n snapshot_sanitizer=self._snapshot_sanitizer,\n )\n return WorkflowEngine(workflow, persistence, traces=self._traces, hooks=self._hooks)", - "start_line": 7, - "end_line": 19, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/workflow.py", - "title": "src/plba/workflow.py:1-18", - "content": "from app_runtime.workflow.contracts.context import WorkflowContext\nfrom app_runtime.workflow.contracts.result import StepResult\nfrom app_runtime.workflow.contracts.step import WorkflowStep\nfrom app_runtime.workflow.contracts.workflow import WorkflowDefinition, WorkflowNode\nfrom app_runtime.workflow.engine.hooks import WorkflowEngineHooks\nfrom app_runtime.workflow.engine.workflow_engine import WorkflowEngine\nfrom app_runtime.workflow.runtime_factory import WorkflowRuntimeFactory\n\n__all__ = [\n \"StepResult\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n]", - "start_line": 1, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/__init__.py", - "title": "src/app_runtime/config/__init__.py:1-4", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/file_loader.py", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "start_line": 11, - "end_line": 48, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/config.py", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/health.py", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/application.py", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "start_line": 8, - "end_line": 16, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default" - } - ], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 21, - "span_end": 30, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "cb7c73db05c2622aac89114bed1cddd1d567de21cfac5c53037c62b1074b25c9", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory\nWorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9da827270329de64ebb426fadaaa5e35145e6666b92c6da186e08bf4b071f458", - "qname": "WorkflowRuntimeFactory", - "kind": "class", - "signature": "WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "80865947d1ca709971efe9d68a9ee1f348c1c43d351bf4e1b4a5884d72985b6b", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.__init__\n__init__(self, connection_factory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.__init__", - "span_start": 8, - "span_end": 12, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "qname": "WorkflowRuntimeFactory.__init__", - "kind": "method", - "signature": "__init__(self, connection_factory)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.create_engine\ncreate_engine(self, workflow)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.create_engine", - "span_start": 14, - "span_end": 19, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "qname": "WorkflowRuntimeFactory.create_engine", - "kind": "method", - "signature": "create_engine(self, workflow)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowPersistence\nWorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowPersistence", - "span_start": 4, - "span_end": 4, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "35693d37698e35079400b6a021d46209966ce469d9f77763d1c82d82ef4600b2", - "qname": "WorkflowPersistence", - "kind": "const", - "signature": "WorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e016ec68f9d15d52fe0505774229fafc705c1bf3dfda78845a3db9b032a4441d", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowEngine\nWorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowEngine", - "span_start": 3, - "span_end": 3, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "da4aee8bc7d248177fbc4f892732c6eb08baa6d268c32921a217747143a99fe0", - "qname": "WorkflowEngine", - "kind": "const", - "signature": "WorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 11, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 12, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 9, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 10, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:writes_attr", - "span_start": 12, - "span_end": 12, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.create_engine:calls", - "span_start": 15, - "span_end": 18, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory:\n def __init__(self, connection_factory=None, *, traces, hooks=None, snapshot_sanitizer=None) -> None:\n self._connection_factory = connection_factory\n self._traces = traces\n self._hooks = hooks\n self._snapshot_sanitizer = snapshot_sanitizer\n\n def create_engine(self, workflow) -> WorkflowEngine:\n persistence = WorkflowPersistence.create_default(\n self._connection_factory,\n snapshot_sanitizer=self._snapshot_sanitizer,\n )\n return WorkflowEngine(workflow, persistence, traces=self._traces, hooks=self._hooks)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/workflow/runtime_factory.py:WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "from app_runtime.workflow.contracts.context import WorkflowContext\nfrom app_runtime.workflow.contracts.result import StepResult\nfrom app_runtime.workflow.contracts.step import WorkflowStep\nfrom app_runtime.workflow.contracts.workflow import WorkflowDefinition, WorkflowNode\nfrom app_runtime.workflow.engine.hooks import WorkflowEngineHooks\nfrom app_runtime.workflow.engine.workflow_engine import WorkflowEngine\nfrom app_runtime.workflow.runtime_factory import WorkflowRuntimeFactory\n\n__all__ = [\n \"StepResult\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/workflow.py:1-18", - "span_start": 1, - "span_end": 18, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 37, - "C2_DEPENDENCY_GRAPH": 31, - "C0_SOURCE_CHUNKS": 11 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": false, - "answer_mode": "degraded", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": false, - "failure_reasons": [ - "tests_not_found" - ], - "evidence_count": 24 - }, - "failure_reasons": [ - "tests_not_found" - ], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 21, - "span_end": 30, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "cb7c73db05c2622aac89114bed1cddd1d567de21cfac5c53037c62b1074b25c9", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory\nWorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9da827270329de64ebb426fadaaa5e35145e6666b92c6da186e08bf4b071f458", - "qname": "WorkflowRuntimeFactory", - "kind": "class", - "signature": "WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "80865947d1ca709971efe9d68a9ee1f348c1c43d351bf4e1b4a5884d72985b6b", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.__init__\n__init__(self, connection_factory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.__init__", - "span_start": 8, - "span_end": 12, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "qname": "WorkflowRuntimeFactory.__init__", - "kind": "method", - "signature": "__init__(self, connection_factory)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.create_engine\ncreate_engine(self, workflow)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.create_engine", - "span_start": 14, - "span_end": 19, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "qname": "WorkflowRuntimeFactory.create_engine", - "kind": "method", - "signature": "create_engine(self, workflow)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowPersistence\nWorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowPersistence", - "span_start": 4, - "span_end": 4, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "35693d37698e35079400b6a021d46209966ce469d9f77763d1c82d82ef4600b2", - "qname": "WorkflowPersistence", - "kind": "const", - "signature": "WorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e016ec68f9d15d52fe0505774229fafc705c1bf3dfda78845a3db9b032a4441d", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowEngine\nWorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowEngine", - "span_start": 3, - "span_end": 3, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "da4aee8bc7d248177fbc4f892732c6eb08baa6d268c32921a217747143a99fe0", - "qname": "WorkflowEngine", - "kind": "const", - "signature": "WorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 11, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 12, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 9, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 10, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:writes_attr", - "span_start": 12, - "span_end": 12, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.create_engine:calls", - "span_start": 15, - "span_end": 18, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory:\n def __init__(self, connection_factory=None, *, traces, hooks=None, snapshot_sanitizer=None) -> None:\n self._connection_factory = connection_factory\n self._traces = traces\n self._hooks = hooks\n self._snapshot_sanitizer = snapshot_sanitizer\n\n def create_engine(self, workflow) -> WorkflowEngine:\n persistence = WorkflowPersistence.create_default(\n self._connection_factory,\n snapshot_sanitizer=self._snapshot_sanitizer,\n )\n return WorkflowEngine(workflow, persistence, traces=self._traces, hooks=self._hooks)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/workflow/runtime_factory.py:WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "from app_runtime.workflow.contracts.context import WorkflowContext\nfrom app_runtime.workflow.contracts.result import StepResult\nfrom app_runtime.workflow.contracts.step import WorkflowStep\nfrom app_runtime.workflow.contracts.workflow import WorkflowDefinition, WorkflowNode\nfrom app_runtime.workflow.engine.hooks import WorkflowEngineHooks\nfrom app_runtime.workflow.engine.workflow_engine import WorkflowEngine\nfrom app_runtime.workflow.runtime_factory import WorkflowRuntimeFactory\n\n__all__ = [\n \"StepResult\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/workflow.py:1-18", - "span_start": 1, - "span_end": 18, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": false, - "action": "repair", - "reasons": [ - "degraded_answer_missing_guardrail" - ] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md deleted file mode 100644 index 8d465e3..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-workflow-runtime-factory-negative - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для WorkflowRuntimeFactory? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Insufficient evidence for a confident answer. No test candidates found.", - "answer_mode": "degraded", - "path_scope": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json deleted file mode 100644 index 0e8578d..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json +++ /dev/null @@ -1,341 +0,0 @@ -{ - "case_id": "plba-v2-open-file-nonexistent", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Открой файл src/app_runtime/core/missing_runtime.py", - "actual": { - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 0, - "llm_answer": "Файл `src/app_runtime/core/missing_runtime.py` не найден.", - "answer_mode": "not_found", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "passed": false, - "mismatches": [ - "answer_mode: expected degraded, got not_found", - "llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.'" - ], - "details": { - "query": "Открой файл src/app_runtime/core/missing_runtime.py", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Открой файл src/app_runtime/core/missing_runtime.py", - "normalized": "Открой файл src/app_runtime/core/missing_runtime.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/app_runtime/core/missing_runtime.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/app_runtime/core/missing_runtime.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 51 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/app_runtime/core/missing_runtime.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "not_requested", - "resolved_symbol": null, - "alternatives": [], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": false, - "require_flow": false, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/app_runtime/core/missing_runtime.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "keyword_hints": [], - "symbol_candidates": [], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/app_runtime/core/missing_runtime.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Открой файл src/app_runtime/core/missing_runtime.py", - "normalized": "Открой файл src/app_runtime/core/missing_runtime.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/app_runtime/core/missing_runtime.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/app_runtime/core/missing_runtime.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 51 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [], - "resolved_symbol": null, - "symbol_resolution_status": "not_requested", - "file_candidates": [], - "code_chunks": [], - "relations": [], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 0, - "empty": true, - "fallback_used": false - } - ], - "missing_layers": [ - "C0_SOURCE_CHUNKS" - ], - "raw_rows": [], - "retrieval_report": { - "executed_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C0_SOURCE_CHUNKS": "exact_path_fetch" - }, - "top_k_by_layer": { - "C0_SOURCE_CHUNKS": 200 - }, - "filters_by_layer": { - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ] - } - }, - "requests": [ - { - "layer": "C0_SOURCE_CHUNKS", - "query": "Открой файл src/app_runtime/core/missing_runtime.py", - "ranking_profile": "code" - } - ], - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 18 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": false, - "layers_used": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": false, - "answer_mode": "insufficient", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "layers": [ - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_requested" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/app_runtime/core/missing_runtime.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 0, - "empty": true, - "fallback_used": false - } - ], - "empty_layers": [ - "C0_SOURCE_CHUNKS" - ], - "evidence_gate_decision": { - "sufficient": false, - "failure_reasons": [ - "path_scope_empty", - "layer_c0_empty" - ], - "evidence_count": 0 - }, - "failure_reasons": [ - "path_scope_empty", - "layer_c0_empty" - ], - "timings_ms": {} - }, - "rag_rows": [], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md deleted file mode 100644 index b301f23..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md +++ /dev/null @@ -1,31 +0,0 @@ -# plba-v2-open-file-nonexistent - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Открой файл src/app_runtime/core/missing_runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 0, - "llm_answer": "Файл `src/app_runtime/core/missing_runtime.py` не найден.", - "answer_mode": "not_found", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- answer_mode: expected degraded, got not_found -- llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json deleted file mode 100644 index bf348ee..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json +++ /dev/null @@ -1,417 +0,0 @@ -{ - "case_id": "plba-v2-open-file-public-api", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Открой файл src/plba/__init__.py", - "actual": { - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь к файлу: src/plba/__init__.py\n\nВ этом файле находятся импорт различных модулей и классов из пакета plba. В частности, здесь можно найти:\n- Импорты для создания runtime с помощью `create_runtime`\n- Классы и интерфейсы конфигурации (`ConfigFileLoader`, `FileConfigProvider`)\n- Контроллеры и каналы управления (`ControlActionSet`, `ControlChannel`, `HttpControlChannel`)\n- Определения контрактов (`ApplicationModule`, `Worker`, etc.)\n- Менеджеры конфигурации и выполнения (`ConfigurationManager`, `RuntimeManager`, `ServiceContainer`)\n- Регистраторы здоровья и службы логирования\n- Обработчики очередей задач и транспортные средства трассировки (`InMemoryTaskQueue`, `MySqlTraceTransport`, `NoOpTraceTransport`)\n- Определение рабочего потока и контекста (`StepResult`, `WorkflowContext`, `WorkflowDefinition`)", - "answer_mode": "answered", - "path_scope": [ - "src/plba/__init__.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Открой файл src/plba/__init__.py", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Открой файл src/plba/__init__.py", - "normalized": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/plba/__init__.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/plba/__init__.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 32 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/plba/__init__.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/plba/__init__.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "not_requested", - "resolved_symbol": null, - "alternatives": [], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": false, - "require_flow": false, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "keyword_hints": [], - "symbol_candidates": [], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/plba/__init__.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/plba/__init__.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Открой файл src/plba/__init__.py", - "normalized": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/plba/__init__.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/plba/__init__.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 32 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [], - "resolved_symbol": null, - "symbol_resolution_status": "not_requested", - "file_candidates": [ - "src/plba/__init__.py" - ], - "code_chunks": [ - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 0, - "prefer_bonus": 0, - "test_penalty": 0, - "structural_rank": 0, - "layer_rank": 0, - "distance": 0, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C0_SOURCE_CHUNKS": "exact_path_fetch" - }, - "top_k_by_layer": { - "C0_SOURCE_CHUNKS": 200 - }, - "filters_by_layer": { - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/plba/__init__.py" - ] - } - }, - "requests": [ - { - "layer": "C0_SOURCE_CHUNKS", - "query": "Открой файл src/plba/__init__.py", - "ranking_profile": "code" - } - ], - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 21 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "layers": [ - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_requested" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 1 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 0, - "prefer_bonus": 0, - "test_penalty": 0, - "structural_rank": 0, - "layer_rank": 0, - "distance": 0, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md deleted file mode 100644 index d650590..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md +++ /dev/null @@ -1,30 +0,0 @@ -# plba-v2-open-file-public-api - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/plba/__init__.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь к файлу: src/plba/__init__.py\n\nВ этом файле находятся импорт различных модулей и классов из пакета plba. В частности, здесь можно найти:\n- Импорты для создания runtime с помощью `create_runtime`\n- Классы и интерфейсы конфигурации (`ConfigFileLoader`, `FileConfigProvider`)\n- Контроллеры и каналы управления (`ControlActionSet`, `ControlChannel`, `HttpControlChannel`)\n- Определения контрактов (`ApplicationModule`, `Worker`, etc.)\n- Менеджеры конфигурации и выполнения (`ConfigurationManager`, `RuntimeManager`, `ServiceContainer`)\n- Регистраторы здоровья и службы логирования\n- Обработчики очередей задач и транспортные средства трассировки (`InMemoryTaskQueue`, `MySqlTraceTransport`, `NoOpTraceTransport`)\n- Определение рабочего потока и контекста (`StepResult`, `WorkflowContext`, `WorkflowDefinition`)", - "answer_mode": "answered", - "path_scope": [ - "src/plba/__init__.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json deleted file mode 100644 index 16cb1a8..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json +++ /dev/null @@ -1,417 +0,0 @@ -{ - "case_id": "plba-v2-open-file-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Открой файл src/app_runtime/core/runtime.py", - "actual": { - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь: src/app_runtime/core/runtime.py\n\nВ этом файле содержится определение класса `RuntimeManager`. В классе инициализируются различные компоненты системы, такие как конфигурация, службы, трассировка, здоровье, журналы, рабочие процессы и контрольная плоскость. Класс предназначен для управления выполнением действий в системе с заданными тайм-аутами и интервалами опроса.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Открой файл src/app_runtime/core/runtime.py", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Открой файл src/app_runtime/core/runtime.py", - "normalized": "Открой файл src/app_runtime/core/runtime.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/app_runtime/core/runtime.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/app_runtime/core/runtime.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 43 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/app_runtime/core/runtime.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "not_requested", - "resolved_symbol": null, - "alternatives": [], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": false, - "require_flow": false, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/app_runtime/core/runtime.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "keyword_hints": [], - "symbol_candidates": [], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 12 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/app_runtime/core/runtime.py" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": false, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Открой файл src/app_runtime/core/runtime.py", - "normalized": "Открой файл src/app_runtime/core/runtime.py", - "sub_intent": "OPEN_FILE", - "negations": [], - "expansions": [ - "file" - ], - "keyword_hints": [], - "path_hints": [ - "src/app_runtime/core/runtime.py" - ], - "doc_scope_hints": [], - "symbol_candidates": [], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "FILE_PATH", - "value": "src/app_runtime/core/runtime.py", - "source": "user_text", - "subtype": null, - "span": { - "start": 12, - "end": 43 - }, - "confidence": 0.95 - }, - { - "type": "KEY_TERM", - "value": "файл", - "source": "user_text", - "subtype": null, - "span": { - "start": 7, - "end": 11 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [], - "resolved_symbol": null, - "symbol_resolution_status": "not_requested", - "file_candidates": [ - "src/app_runtime/core/runtime.py" - ], - "code_chunks": [ - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/core/runtime.py", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "start_line": 18, - "end_line": 179, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 0, - "test_penalty": 0, - "structural_rank": 0, - "layer_rank": 0, - "distance": 0, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C0_SOURCE_CHUNKS": "exact_path_fetch" - }, - "top_k_by_layer": { - "C0_SOURCE_CHUNKS": 200 - }, - "filters_by_layer": { - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/app_runtime/core/runtime.py" - ] - } - }, - "requests": [ - { - "layer": "C0_SOURCE_CHUNKS", - "query": "Открой файл src/app_runtime/core/runtime.py", - "ranking_profile": "code" - } - ], - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 127 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "layers": [ - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_requested" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/app_runtime/core/runtime.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 1 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager:\n ACTION_TIMEOUT_SECONDS = 10.0\n ACTION_POLL_INTERVAL_SECONDS = 0.05\n\n def __init__(\n self,\n configuration: ConfigurationManager | None = None,\n services: ServiceContainer | None = None,\n traces: TraceService | None = None,\n health: HealthRegistry | None = None,\n logs: LogManager | None = None,\n workers: WorkerSupervisor | None = None,\n control_plane: ControlPlaneService | None = None,\n ) -> None:\n self.configuration = configuration or ConfigurationManager()\n self.services = services or ServiceContainer()\n self.traces = traces or TraceService()\n self.health = health or HealthRegistry()\n self.logs = logs or LogManager()\n self.workers = workers or WorkerSupervisor()\n self.control_plane = control_plane or ControlPlaneService()\n self.registry = ModuleRegistry(self.services)\n self._started = False\n self._state = LifecycleState.IDLE\n self._core_registered = False\n self._workers_registered = False\n self._register_core_services()\n\n def register_module(self, module: ApplicationModule) -> None:\n self.registry.register_module(module.name)\n module.register(self.registry)\n\n def add_config_file(self, path: str) -> FileConfigProvider:\n provider = FileConfigProvider(path)\n self.configuration.add_provider(provider)\n return provider\n\n def start(self, *, start_control_plane: bool = True) -> None:\n if self._started:\n return\n self._state = LifecycleState.STARTING\n config = self.configuration.load()\n self.logs.apply_config(config)\n self._register_health_contributors()\n self._register_workers()\n self.workers.start()\n if start_control_plane:\n self.control_plane.start(self)\n self._started = True\n self._refresh_state()\n\n def stop(self, timeout: float = 30.0, force: bool = False, stop_control_plane: bool = True) -> None:\n if not self._started:\n return\n self._state = LifecycleState.STOPPING\n self.workers.stop(timeout=timeout, force=force)\n if stop_control_plane:\n self.control_plane.stop()\n self._started = False\n self._state = LifecycleState.STOPPED\n\n def status(self) -> dict[str, object]:\n self._refresh_state()\n return self.control_plane.snapshot(self)\n\n def current_health(self) -> HealthPayload:\n self._refresh_state()\n return self.health.payload(self._state, self.workers.healths())\n\n async def health_status(self) -> HealthPayload:\n return self.current_health()\n\n async def start_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if self._started:\n return \"runtime already running\"\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self.start(start_control_plane=False)\n started = self._wait_for_state({LifecycleState.IDLE, LifecycleState.BUSY}, timeout=self.ACTION_TIMEOUT_SECONDS)\n if started:\n return self._action_detail(\"runtime started\", timed_out=False)\n return self._action_detail(\"runtime start is still in progress\", timed_out=True)\n\n async def stop_runtime(self) -> dict[str, object] | str:\n self._refresh_state()\n if not self._started:\n if self._state == LifecycleState.STOPPING:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n return \"runtime already stopped\"\n\n self._state = LifecycleState.STOPPING\n try:\n self.workers.stop(timeout=self.ACTION_TIMEOUT_SECONDS, force=False)\n except TimeoutError:\n return self._action_detail(\"runtime stop is still in progress\", timed_out=True)\n\n self._started = False\n self._state = LifecycleState.STOPPED\n return self._action_detail(\"runtime stopped\", timed_out=False)\n\n async def runtime_status(self) -> str:\n self._refresh_state()\n return self._state.value\n\n def _register_core_services(self) -> None:\n if self._core_registered:\n return\n self.services.register(\"configuration\", self.configuration)\n self.services.register(\"traces\", self.traces)\n self.services.register(\"health\", self.health)\n self.services.register(\"logs\", self.logs)\n self.services.register(\"workers\", self.workers)\n self.services.register(\"control_plane\", self.control_plane)\n self._core_registered = True\n\n def _register_health_contributors(self) -> None:\n for contributor in self.registry.health_contributors:\n self.health.register(contributor)\n\n def _register_workers(self) -> None:\n if self._workers_registered:\n return\n for worker in self.registry.workers:\n self.workers.register(worker)\n self._workers_registered = True\n\n def _refresh_state(self) -> None:\n lifecycle = self.workers.lifecycle_state()\n\n if self._state == LifecycleState.STOPPING:\n if lifecycle == LifecycleState.STOPPED:\n self._started = False\n self._state = LifecycleState.STOPPED\n return\n\n if not self._started:\n if lifecycle == LifecycleState.STOPPED:\n self._state = LifecycleState.STOPPED\n return\n\n self._state = lifecycle\n\n def _wait_for_state(self, target_states: set[LifecycleState], *, timeout: float) -> bool:\n deadline = monotonic() + timeout\n while monotonic() < deadline:\n self._refresh_state()\n if self._state in target_states:\n return True\n sleep(self.ACTION_POLL_INTERVAL_SECONDS)\n self._refresh_state()\n return self._state in target_states\n\n def _action_detail(self, message: str, *, timed_out: bool) -> dict[str, object]:\n self._refresh_state()\n return {\n \"message\": message,\n \"state\": self._state.value,\n \"timed_out\": timed_out,\n \"workers\": self.workers.snapshot(),\n }", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/core/runtime.py:RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 0, - "test_penalty": 0, - "structural_rank": 0, - "layer_rank": 0, - "distance": 0, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md deleted file mode 100644 index 6b4b80b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md +++ /dev/null @@ -1,30 +0,0 @@ -# plba-v2-open-file-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/app_runtime/core/runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Путь: src/app_runtime/core/runtime.py\n\nВ этом файле содержится определение класса `RuntimeManager`. В классе инициализируются различные компоненты системы, такие как конфигурация, службы, трассировка, здоровье, журналы, рабочие процессы и контрольная плоскость. Класс предназначен для управления выполнением действий в системе с заданными тайм-аутами и интервалами опроса.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json deleted file mode 100644 index b3155d7..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json +++ /dev/null @@ -1,4707 +0,0 @@ -{ - "case_id": "plba-v2-trace-flow-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "actual": { - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. HttpControlAppFactory.create(health_provider, action_provider)\n - Создает FastAPI приложение.\n - Добавляет middleware для логирования времени ответа.\n - Обрабатывает GET запрос к \"/health\".\n\n2. HttpControlAppFactory.create.health()\n - Вызывается при обработке запроса \"/health\".\n - Возвращает Awaitable объект типа HealthPayload.\n\n3. HttpControlAppFactory.create.action_provider()\n - Определяет поведение при запросе действий.\n\nПолный поток вызова от обработки запроса \"/health\" до получения HealthPayload отсутствует в предоставленных доказательствах.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Покажи как проходит запрос /health в HttpControlAppFactory", - "normalized": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "negations": [], - "expansions": [ - "health", - "HttpControlAppFactory" - ], - "keyword_hints": [ - "health", - "HttpControlAppFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "SYMBOL", - "value": "health", - "source": "user_text", - "subtype": null, - "span": { - "start": 28, - "end": 34 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "HttpControlAppFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 37, - "end": 58 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 10 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "health", - "HttpControlAppFactory" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "keyword_hints": [ - "health", - "HttpControlAppFactory" - ], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 10 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Покажи как проходит запрос /health в HttpControlAppFactory", - "normalized": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "negations": [], - "expansions": [ - "health", - "HttpControlAppFactory" - ], - "keyword_hints": [ - "health", - "HttpControlAppFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "symbol_kind_hint": "unknown", - "anchors": [ - { - "type": "SYMBOL", - "value": "health", - "source": "user_text", - "subtype": null, - "span": { - "start": 28, - "end": 34 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "HttpControlAppFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 37, - "end": 58 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "HttpControlAppFactory", - "ControlActionSet", - "ControlPlaneService", - "HealthContributor.health", - "HealthContributor", - "ControlChannel" - ], - "resolved_symbol": "HttpControlAppFactory", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/contracts/health.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/service.py", - "src/app_runtime/health/registry.py", - "src/app_runtime/core/types.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "class HttpControlAppFactory\nHttpControlAppFactory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "qname": "HttpControlAppFactory", - "kind": "class", - "signature": "HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlAppFactory", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "start_line": 8, - "end_line": 8, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "class ControlActionSet\nControlActionSet", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/contracts/health.py", - "title": "HealthContributor.health", - "content": "method HealthContributor.health\nhealth(self)\nReturn contributor health state.", - "start_line": 9, - "end_line": 10, - "metadata": { - "symbol_id": "728cff18958d8a25e2661a0f08c83d68c3bbbfa8cef212b85dc0da2b11b3dc90", - "qname": "HealthContributor.health", - "kind": "method", - "signature": "health(self)", - "parent_symbol_id": "HealthContributor", - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/contracts/health.py", - "title": "HealthContributor", - "content": "class HealthContributor\nHealthContributor(ABC)", - "start_line": 7, - "end_line": 10, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "qname": "HealthContributor", - "kind": "class", - "signature": "HealthContributor(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/health.py", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/health/registry.py", - "title": "HealthRegistry", - "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)", - "start_line": 8, - "end_line": 56, - "metadata": { - "symbol_id": "fd3390eb0ba29c9979466b9c2117238e0da3bb829eeb4d505cb34c9c3df7a8e8", - "symbol_name": "HealthRegistry", - "qname": "HealthRegistry", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 2, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/core/types.py", - "title": "HealthPayload", - "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 7, - "end_line": 11, - "metadata": { - "symbol_id": "392235d63ddf752d6e419cb8528c93fe070d1bc02d3c87ba6a897baac810cf5d", - "symbol_name": "HealthPayload", - "qname": "HealthPayload", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "448a02e4a432b5ab65b246b2bd24a32a6f127b9d2091ea73b53ee3c0a2f53bb3", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/contracts/health.py", - "title": "HealthContributor", - "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 7, - "end_line": 10, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "symbol_name": "HealthContributor", - "qname": "HealthContributor", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/health/registry.py", - "title": "HealthRegistry.__init__:dataflow_slice", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register", - "start_line": 10, - "end_line": 13, - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/health/registry.py", - "title": "HealthRegistry.__init__:dataflow_slice", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths", - "start_line": 10, - "end_line": 16, - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory.create:calls", - "content": "HttpControlAppFactory.create calls time.monotonic", - "start_line": 25, - "end_line": 25, - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory.create:calls", - "content": "HttpControlAppFactory.create calls app.post", - "start_line": 37, - "end_line": 37, - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory.create:calls", - "content": "HttpControlAppFactory.create calls str", - "start_line": 27, - "end_line": 27, - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/health/registry.py", - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/health/registry.py", - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/http_app.py", - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlAppFactory.create calls time.monotonic" - }, - { - "path": "src/app_runtime/control/http_app.py", - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlAppFactory.create calls app.post" - }, - { - "path": "src/app_runtime/control/http_app.py", - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "HttpControlAppFactory.create calls str" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory\nHttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "qname": "HttpControlAppFactory", - "kind": "class", - "signature": "HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 8, - "span_end": 8, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "method HealthContributor.health\nhealth(self)\nReturn contributor health state.", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor.health", - "span_start": 9, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "728cff18958d8a25e2661a0f08c83d68c3bbbfa8cef212b85dc0da2b11b3dc90", - "qname": "HealthContributor.health", - "kind": "method", - "signature": "health(self)", - "parent_symbol_id": "HealthContributor", - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor\nHealthContributor(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "qname": "HealthContributor", - "kind": "class", - "signature": "HealthContributor(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthRegistry", - "span_start": 8, - "span_end": 56, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 29, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd3390eb0ba29c9979466b9c2117238e0da3bb829eeb4d505cb34c9c3df7a8e8", - "symbol_name": "HealthRegistry", - "qname": "HealthRegistry", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 2, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/types.py", - "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthPayload", - "span_start": 7, - "span_end": 11, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "392235d63ddf752d6e419cb8528c93fe070d1bc02d3c87ba6a897baac810cf5d", - "symbol_name": "HealthPayload", - "qname": "HealthPayload", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "448a02e4a432b5ab65b246b2bd24a32a6f127b9d2091ea73b53ee3c0a2f53bb3", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "symbol_name": "HealthContributor", - "qname": "HealthContributor", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 13, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls time.monotonic", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 25, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls app.post", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 37, - "span_end": 37, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls str", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 27, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 10, - "C3_ENTRYPOINTS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 56, - "C0_SOURCE_CHUNKS": 25, - "C4_SEMANTIC_ROLES": 24, - "C2_DEPENDENCY_GRAPH": 64, - "C3_ENTRYPOINTS": 15 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 37 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory\nHttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "qname": "HttpControlAppFactory", - "kind": "class", - "signature": "HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const HttpControlAppFactory\nHttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "HttpControlAppFactory", - "span_start": 8, - "span_end": 8, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9ee00379ee797cd2386e88a6e37dc69e3e31de9144fc4b95f0206cd1430e8983", - "qname": "HttpControlAppFactory", - "kind": "const", - "signature": "HttpControlAppFactory = app_runtime.control.http_app.HttpControlAppFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "method HealthContributor.health\nhealth(self)\nReturn contributor health state.", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor.health", - "span_start": 9, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "728cff18958d8a25e2661a0f08c83d68c3bbbfa8cef212b85dc0da2b11b3dc90", - "qname": "HealthContributor.health", - "kind": "method", - "signature": "health(self)", - "parent_symbol_id": "HealthContributor", - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor\nHealthContributor(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "qname": "HealthContributor", - "kind": "class", - "signature": "HealthContributor(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthRegistry", - "span_start": 8, - "span_end": 56, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 29, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd3390eb0ba29c9979466b9c2117238e0da3bb829eeb4d505cb34c9c3df7a8e8", - "symbol_name": "HealthRegistry", - "qname": "HealthRegistry", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 2, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/types.py", - "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthPayload", - "span_start": 7, - "span_end": 11, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "392235d63ddf752d6e419cb8528c93fe070d1bc02d3c87ba6a897baac810cf5d", - "symbol_name": "HealthPayload", - "qname": "HealthPayload", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "448a02e4a432b5ab65b246b2bd24a32a6f127b9d2091ea73b53ee3c0a2f53bb3", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "db91ae387b89a2e9d83829754f27fa18a4055b3e72d7f31789a0b8e0bf5bba0b", - "symbol_name": "HealthContributor", - "qname": "HealthContributor", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.register", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 13, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2", - "dst_ref": "HealthRegistry.register", - "resolution": "resolved", - "slice_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.register" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "a9e1f290c346c8bb1d67af0cafeebb5bcaf29c3ed7027e33c794532743df38f2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/health/registry.py", - "content": "HealthRegistry.__init__\n -> HealthRegistry._contributors\n -> HealthRegistry.contributor_healths", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HealthRegistry.__init__:dataflow_slice", - "span_start": 10, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "edge_type": "dataflow_slice", - "src_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "src_qname": "HealthRegistry.__init__", - "dst_symbol_id": "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2", - "dst_ref": "HealthRegistry.contributor_healths", - "resolution": "resolved", - "slice_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", - "root_symbol_id": "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "path_symbols": [ - "HealthRegistry.__init__", - "HealthRegistry._contributors", - "HealthRegistry.contributor_healths" - ], - "path_symbol_ids": [ - "e8ffd58441c231de43d9e86c31eb12303d4e2bf045b2acf13d1dfe78da01f8dc", - "fa7bbd8f4b64a55a5088640c30f52e84075d65f531bd7e1f6c1d7bb8d24fcbf2" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "26e6a24daa43407ba5340b74497c20153020e79f8d7828ae502aaec378dfcf75", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls time.monotonic", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 25, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "time.monotonic", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls app.post", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 37, - "span_end": 37, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "app.post", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory.create calls str", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "HttpControlAppFactory.create:calls", - "span_start": 27, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", - "edge_type": "calls", - "src_symbol_id": "4af42c2a9275d652e710a98ec48b8247236b4453a093629f8958704ff6d3cb58", - "src_qname": "HttpControlAppFactory.create", - "dst_symbol_id": null, - "dst_ref": "str", - "resolution": "partial", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md deleted file mode 100644 index 5f8dc3b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md +++ /dev/null @@ -1,35 +0,0 @@ -# plba-v2-trace-flow-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи как проходит запрос /health в HttpControlAppFactory - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. HttpControlAppFactory.create(health_provider, action_provider)\n - Создает FastAPI приложение.\n - Добавляет middleware для логирования времени ответа.\n - Обрабатывает GET запрос к \"/health\".\n\n2. HttpControlAppFactory.create.health()\n - Вызывается при обработке запроса \"/health\".\n - Возвращает Awaitable объект типа HealthPayload.\n\n3. HttpControlAppFactory.create.action_provider()\n - Определяет поведение при запросе действий.\n\nПолный поток вызова от обработки запроса \"/health\" до получения HealthPayload отсутствует в предоставленных доказательствах.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md deleted file mode 100644 index 12448a5..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-trace-flow-runtime-start - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи поток выполнения при запуске RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "1. Запускается `RuntimeManager` через импорт в `bootstrap.py` (`src/plba/bootstrap.py:4`).\n2. Далее, в `control/service.py`, происходит повторный импорт и переопределение переменной `RuntimeManager` как `app_runtime.core.runtime.RuntimeManager` (`src/app_runtime/control/service.py:9`).\n3. В файле `core/runtime.py` начинается определение класса `RuntimeManager`. Этот класс управляет состоянием приложения и участвует в управлении жизненным циклом различных сервисов и модулей (`src/app_runtime/core/runtime.py:18-179`).\n4. Из `__init__.py` модуля `plba` (`src/plba/__init__.py:16`) импортируется другой экземпляр `RuntimeManager`.\n5. Затем идет обращение к инициализации объекта `ControlPlaneService` в модуле `control/service.py` (`src/app_runtime/control/service.py:12-52`), который регистрирует каналы управления.\n6. Контроллер канала управления определяется в `base.py` файла `control` и имеет методы для запуска и остановки каналов (`src/app_runtime/control/base.py:21-28`).\n7. В `control/http_channel.py` создается объект `HttpControlChannel`, управляющий HTTP-запросами с использованием библиотеки uvicorn (`src/app_runtime/control/http_channel.py:12-57`).\n8. Модуль `control/http_app.py` создает фабрику приложений для обработки HTTP-запросов, связанных с управлением состоянием системы (`src/app_runtime/control/http_app.py:15-53`).\n9. Инициализация конфигурации и параметров происходит в методах `_register_core_services` и `_start_async` внутри класса `RuntimeManager` (`src/app_runtime/core/runtime.py:32-127`).\n\nПолный путь вызова:\n\n1. `src/plba/bootstrap.py`\n2. `src/app_runtime/control/service.py`\n3. `src/app_runtime/core/runtime.py`\n4. `src/plba/__init__.py`\n5. `src/app_runtime/control/service.py`\n6. `src/app_runtime/control/base.py`\n7. `src/app_runtime/control/http_channel.py`\n8. `src/app_runtime/control/http_app.py`\n9. `src/app_runtime/core/runtime.py`", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/summary.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/summary.md deleted file mode 100644 index 666ba7f..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/summary.md +++ /dev/null @@ -1,85 +0,0 @@ -# pipeline_setup_v3 summary - -Passed: 15/18 - -| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | -|------|------|------|-------|-------------------|------------|------| -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-public-api | full_chain | Открой файл src/plba/__init__.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-trace-service | full_chain | Объясни как работает класс TraceService | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-create-runtime | full_chain | Что делает функция create_runtime? | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-trace-service | full_chain | Где тесты для TraceService? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-create-runtime | full_chain | Где тесты для create_runtime? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-workflow-runtime-factory-negative | full_chain | Где тесты для WorkflowRuntimeFactory? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-control-plane | full_chain | Найди точки входа HTTP control plane | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-health-endpoint | full_chain | Покажи как проходит запрос /health в HttpControlAppFactory | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-control-plane | full_chain | Какие компоненты участвуют в ControlPlaneService? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✗ | - -## Failures -- **plba-v2-find-entrypoints-health-endpoint**: llm: expected answer to contain 'GET /health' -- **plba-v2-explain-nonexistent-symbol**: answer_mode: expected degraded, got answered; retrieval: expected empty rag, got 33 rows; llm: expected answer to contain 'не найдена' -- **plba-v2-open-file-nonexistent**: answer_mode: expected degraded, got not_found; llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.' - -## LLM Answers -- **plba-v2-open-file-runtime** - Query: Открой файл src/app_runtime/core/runtime.py - > Путь: src/app\_runtime/core/runtime.py В этом файле содержится определение класса \`RuntimeManager\`. В классе инициализируются различные компоненты системы, такие как конфигурация, службы, трассировка, здоровье, журналы, рабочие процессы и контрольная плоскость. Класс предназначен для управления выполнением действий в системе с заданными тайм\-аутами и интервалами опроса. -- **plba-v2-open-file-public-api** - Query: Открой файл src/plba/__init__.py - > Путь к файлу: src/plba/\_\_init\_\_.py В этом файле находятся импорт различных модулей и классов из пакета plba. В частности, здесь можно найти: \- Импорты для создания runtime с помощью \`create\_runtime\` \- Классы и интерфейсы конфигурации \(\`ConfigFileLoader\`, \`FileConfigProvider\`\) \- Контроллеры и каналы управления \(\`ControlActionSet\`, \`ControlChannel\`, \`HttpControlChannel\`\) \- Определения контрактов \(\`ApplicationModule\`, \`Worker\`, etc.\) \- Менеджеры конфигурации и выполнения \(\`ConfigurationManager\`, \`RuntimeManager\`, \`ServiceContainer\`\) \- Регистраторы здоровья и службы логирования \- Обработчики очередей задач и транспортные средства трассировки \(\`InMemoryTaskQueue\`, \`MySqlTraceTransport\`, \`NoOpTraceTransport\`\) \- Определение рабочего потока и контекста \(\`StepResult\`, \`WorkflowContext\`, \`WorkflowDefinition\`\) -- **plba-v2-explain-runtime-manager** - Query: Объясни как работает класс RuntimeManager - > Класс \`RuntimeManager\` играет ключевую роль в управлении выполнением приложений и координации различных компонентов системы. Его основная функция заключается в оркестрации действий, связанных с жизненным циклом приложения, включая инициализацию, запуск и остановку сервисов и модулей. \*\*Ключевые шаги работы класса:\*\* 1. Инициализация конфигурации и состояния \(\`\_\_init\_\_\`\). 2. Добавление конфигурационных файлов и настроек \(\`add\_config\_file\`\). 3. Управление состоянием выполнения через чтение и запись атрибутов состояния \(\`configuration\`, \`\_state\`\). 4. Оркестровка вызова методов запуска и остановки для различных компонентов \(\`start\`, \`stop\`\). 5. Участие в обработке данных потока и управлении потоками задач \(\`participates in dataflow slices\`\). \*\*Опорные файлы:\*\* \- \`src/app\_runtime/core/runtime.py:18\-179\` \- \`src/app\_runtime/control/service.py:12\-52\` \- \`src/app\_runtime/contr… -- **plba-v2-explain-trace-service** - Query: Объясни как работает класс TraceService - > Класс \`TraceService\` является основным компонентом системы отслеживания трассировок в приложении. Его основная функция заключается в управлении контекстом трассировки и записи событий в журнал. \*\*Ключевые шаги работы класса:\*\* 1. Инициализация с передачей транспорта \(\`transport\`\) и хранилища контекста \(\`store\`\), которые могут быть опциональными. 2. Создание нового контекста трассировки через метод \`create\_context\`, который генерирует уникальный идентификатор трассы и сохраняет запись о контексте в хранилище. 3. Управление текущим контекстом трассировки через методы: \- \`current\_trace\_id\`: возвращает текущий идентификатор трассировки. \- \`open\_context\`: открывает новый контекст трассировки. \- \`close\_context\`: закрывает текущий контекст трассировки. \*\*Опорные файлы:\*\* \- \`src/app\_runtime/tracing/service.py:39\-166\` \- \`src/app\_runtime/tracing/service.py:66\-78\` \- \`src/app\_ru… -- **plba-v2-explain-create-runtime** - Query: Что делает функция create_runtime? - > Функция \`create\_runtime\` инициализирует и настраивает менеджер выполнения приложения. \*\*Ключевые шаги:\*\* 1. Создает экземпляр менеджера выполнения \(\`RuntimeManager\`\). 2. При наличии указанного пути к конфигурационному файлу добавляет его в менеджер. 3. Если включена опция HTTP\-контроля, регистрирует канал управления с указанными параметрами хоста, порта и тайм\-аута. 4. Регистрирует указанный модуль приложения в менеджере. 5. Возвращает созданный менеджер выполнения. \*\*Опорные файлы:\*\* \- \`src/plba/bootstrap.py:8\-29\` -- **plba-v2-explain-local-http-channel** - Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - > Класс \`HttpControlChannel\` в файле \`src/app\_runtime/control/http\_channel.py\` реализует механизм управления HTTP\-каналом для взаимодействия с внешними сервисами или компонентами. \*\*Ключевые шаги его реализации:\*\* 1. Инициализация класса: \- При создании экземпляра устанавливается таймаут \(\`\_timeout\`\), запускается сервер через объект \`UvicornThreadRunner\`, создается фабрика приложений \`HttpControlAppFactory\`. 2. Запуск канала: \- Метод \`start\` инициализирует набор действий \(\`actions\`\) и создает приложение для работы с ними. Затем запускает сервер через ранее созданный объект \`UvicornThreadRunner\`. 3. Остановка канала: \- Метод \`stop\` останавливает запущенный сервер. Опорные файлы: \- \`src/app\_runtime/control/http\_channel.py\`: определение и реализация класса \`HttpControlChannel\`. -- **plba-v2-find-tests-runtime-manager** - Query: Где тесты для RuntimeManager? - > \- tests/test\_runtime.py:12\-12 \- tests/test\_business\_control\_actions.py:14\-14 -- **plba-v2-find-tests-trace-service** - Query: Где тесты для TraceService? - > \- tests/test\_runtime.py:test\_trace\_service\_allows\_messages\_without\_status \(line range: 279\-293\) \- tests/test\_runtime.py:test\_trace\_service\_writes\_contexts\_and\_messages \(line range: 246\-259\) \- tests/test\_runtime.py:test\_trace\_service\_supports\_debug\_warning\_and\_error\_levels \(line range: 262\-276\) -- **plba-v2-find-tests-create-runtime** - Query: Где тесты для create_runtime? - > \- tests/test\_runtime.py:342\-405 -- **plba-v2-find-tests-workflow-runtime-factory-negative** - Query: Где тесты для WorkflowRuntimeFactory? - > Insufficient evidence for a confident answer. No test candidates found. -- **plba-v2-find-entrypoints-control-plane** - Query: Найди точки входа HTTP control plane - > Confirmed Entrypoints: 1. src/app\_runtime/control/http\_app.py:app.post \(lines 38\-42\) 2. src/app\_runtime/control/http\_app.py:app.get \(lines 31\-34\) 3. src/app\_runtime/control/http\_app.py:app.get \(lines 38\-42\) -- **plba-v2-find-entrypoints-health-endpoint** - Query: Где health endpoint? - > health endpoint: \- src/app\_runtime/control/http\_app.py:38\-42 \(app.post\) \- src/app\_runtime/control/http\_app.py:31\-34 \(app.get\) -- **plba-v2-trace-flow-runtime-start** - Query: Покажи поток выполнения при запуске RuntimeManager - > 1. Запускается \`RuntimeManager\` через импорт в \`bootstrap.py\` \(\`src/plba/bootstrap.py:4\`\). 2. Далее, в \`control/service.py\`, происходит повторный импорт и переопределение переменной \`RuntimeManager\` как \`app\_runtime.core.runtime.RuntimeManager\` \(\`src/app\_runtime/control/service.py:9\`\). 3. В файле \`core/runtime.py\` начинается определение класса \`RuntimeManager\`. Этот класс управляет состоянием приложения и участвует в управлении жизненным циклом различных сервисов и модулей \(\`src/app\_runtime/core/runtime.py:18\-179\`\). 4. Из \`\_\_init\_\_.py\` модуля \`plba\` \(\`src/plba/\_\_init\_\_.py:16\`\) импортируется другой экземпляр \`RuntimeManager\`. 5. Затем идет обращение к инициализации объекта \`ControlPlaneService\` в модуле \`control/service.py\` \(\`src/app\_runtime/control/service.py:12\-52\`\), который регистрирует каналы управления. 6. Контроллер канала управления определяется в \`base.py\` фай… -- **plba-v2-trace-flow-health-endpoint** - Query: Покажи как проходит запрос /health в HttpControlAppFactory - > 1. HttpControlAppFactory.create\(health\_provider, action\_provider\) \- Создает FastAPI приложение. \- Добавляет middleware для логирования времени ответа. \- Обрабатывает GET запрос к "/health". 2. HttpControlAppFactory.create.health\(\) \- Вызывается при обработке запроса "/health". \- Возвращает Awaitable объект типа HealthPayload. 3. HttpControlAppFactory.create.action\_provider\(\) \- Определяет поведение при запросе действий. Полный поток вызова от обработки запроса "/health" до получения HealthPayload отсутствует в предоставленных доказательствах. -- **plba-v2-architecture-runtime-manager** - Query: Какие компоненты участвуют в RuntimeManager? - > \#\#\# Подтвержденные Связи 1. \*\*RuntimeManager\*\*: \- Является ключевым компонентом управления жизненным циклом приложения. \- Инициализирует и управляет другими компонентами системы через метод \`\_\_init\_\_\`. 2. \*\*ControlPlaneService\*\*: \- Управляет каналами контроля. \- Вызывается из метода инициализации \`RuntimeManager\` для регистрации каналов. 3. \*\*ControlChannel\*\*: \- Абстрактный класс для реализации конкретных каналов контроля. \- Реализует методы \`start\` и \`stop\`, которые вызываются сервисами и менеджерами. 4. \*\*ConfigFileLoader\*\*: \- Загружает конфигурационные файлы и передает их в runtime\-менеджер. 5. \*\*WorkflowPersistence\*\*: \- Обеспечивает сохранение информации о workflows. 6. \*\*InMemoryTaskQueue\*\*: \- Используется для хранения задач внутри памяти. 7. \*\*TraceContextStore\*\*: \- Хранит контекст трассировки. 8. \*\*WorkerSupervisor\*\*: \- Наблюдает за рабочими процессами и управ… -- **plba-v2-architecture-control-plane** - Query: Какие компоненты участвуют в ControlPlaneService? - > \#\#\# Подтвержденные Связи 1. \*\*ControlPlaneService\*\*: \- Вызывает методы инициализации \(\`\_channels\`, \`\_start\_async\`, \`register\_channel\`, \`start\`, \`stop\`, \`\_stop\_async\`\) \[evidence: 16\-20\]. 2. \*\*ControlPlaneService\*\* взаимодействует с другими компонентами через методы регистрации каналов и запуска: \- Регистрация канала \(\`register\_channel\`\) использует атрибут \`\_channels\` для хранения списка зарегистрированных каналов \[evidence: 22\]. \- Запуск сервиса использует метод \`start\`, который также обращается к атрибуту \`\_channels\` \[evidence: 23\]. \#\#\# Роли Компонентов 1. \*\*ControlPlaneService\*\*: \- Pipeline stage: отвечает за чтение и запись состояния атрибутов, участвует в данных срезах \(dataflow slices\). 2. \*\*ControlChannel\*\*: \- Model: выполняет функции модели управления каналами, включая запуск и остановку. 3. \*\*ControlActionSet\*\*: \- Default model role: обеспечивает стандартные д… -- **plba-v2-explain-nonexistent-symbol** - Query: Объясни класс RuntimeFactoryManager - > Класс \`RuntimeFactoryManager\` не найден в предоставленном коде или контекстной информации. Ключевые шаги и опорные файлы: 1. Код и контекста относятся к управлению каналами управления \(«control channels»\) в приложении. 2. Основные классы включают \`ControlChannel\`, \`ControlActionSet\`, и связанные с ними каналы и сервисы. 3. Основной файл для рассмотрения — \`base.py\`. 4. Ключевые обязанности и интерфейсы описаны через абстрактные методы \(\`start\`, \`stop\`\) в классе \`ControlChannel\`. Поскольку конкретный класс \`RuntimeFactoryManager\` отсутствует в данном контексте, невозможно предоставить его объяснение. -- **plba-v2-open-file-nonexistent** - Query: Открой файл src/app_runtime/core/missing_runtime.py - > Файл \`src/app\_runtime/core/missing\_runtime.py\` не найден. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json deleted file mode 100644 index 6449f68..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json +++ /dev/null @@ -1,4171 +0,0 @@ -{ - "case_id": "plba-v2-architecture-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "В архитектуре подсистемы ControlPlaneService участвуют следующие основные компоненты:\n\n1. **ControlPlaneService** – главный сервис, инициализирующий и управляющий каналами контроля. Он создает каналы, регистрирует их и управляет жизненным циклом через методы `register_channel`, `start` и `stop`.\n - Создаёт экземпляры каналов (`ControlChannel`) и сохраняет их в поле `_channels`.\n - Вызывает асинхронную инициализацию каналов с помощью методов `start` и `stop`.\n\n2. **ControlChannel** – абстрактный базовый класс для каналов управления, определяющий интерфейс для старта и остановки канала.\n - Описывает абстракции для начала работы канала и освобождения ресурсов при завершении.\n\n3. **ControlActionSet** – модель действий, используемых в канале управления.\n\nСвязи между компонентами реализованы следующим образом:\n- **ControlPlaneService** создаёт и регистрирует экземпляры каналов управления через метод `register_channel`.\n- Каналы управления (например, HttpControlChannel) используют общий интерфейс `ControlChannel` для реализации своих функций старта и завершения.\n\nГраницы ответственности включают управление жизненным циклом каналов и координацию взаимодействия различных компонентов через зарегистрированные каналы.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Какие компоненты участвуют в ControlPlaneService?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Какие компоненты участвуют в ControlPlaneService?", - "normalized": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "negations": [], - "expansions": [ - "ControlPlaneService" - ], - "keyword_hints": [ - "ControlPlaneService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "ControlPlaneService", - "source": "user_text", - "subtype": null, - "span": { - "start": 29, - "end": 48 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 12 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 8 - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "ControlPlaneService" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "keyword_hints": [ - "ControlPlaneService" - ], - "symbol_candidates": [ - "ControlPlaneService" - ], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 12 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 8 - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 4 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Какие компоненты участвуют в ControlPlaneService?", - "normalized": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "negations": [], - "expansions": [ - "ControlPlaneService" - ], - "keyword_hints": [ - "ControlPlaneService" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "ControlPlaneService", - "source": "user_text", - "subtype": null, - "span": { - "start": 29, - "end": 48 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "ControlPlaneService", - "ControlChannel" - ], - "resolved_symbol": "ControlPlaneService", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/app_runtime/control/service.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/http_app.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/workers/supervisor.py", - "src/app_runtime/workflow/engine/workflow_engine.py", - "src/app_runtime/core/runtime.py", - "src/plba/control.py", - "src/app_runtime/control/__init__.py", - "src/plba/__init__.py" - ], - "code_chunks": [ - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "title": "WorkflowEngine", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 86, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.start:calls", - "content": "ControlPlaneService.start calls asyncio.run", - "start_line": 22, - "end_line": 22, - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.register_channel:reads_attr", - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.start:reads_attr", - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels", - "start_line": 20, - "end_line": 20, - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "3030804d119fa1d4b8a6c32616062a5e11080b03d33818c9280bcc5bdd8fd512", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/control.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "bd7f620031a049b8d791534536941ce75071029542395a7bb14817742827070a", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "class ControlPlaneService\nControlPlaneService", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "qname": "ControlPlaneService", - "kind": "class", - "signature": "ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = plba.control.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "90b154d49d544efb7c448e91bf5b75231578a6571b98c06a2a555fa5dcffb152", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = plba.control.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.start calls asyncio.run" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start calls asyncio.run", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:calls", - "span_start": 22, - "span_end": 22, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:reads_attr", - "span_start": 20, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "3030804d119fa1d4b8a6c32616062a5e11080b03d33818c9280bcc5bdd8fd512", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bd7f620031a049b8d791534536941ce75071029542395a7bb14817742827070a", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService\nControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "qname": "ControlPlaneService", - "kind": "class", - "signature": "ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = plba.control.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "90b154d49d544efb7c448e91bf5b75231578a6571b98c06a2a555fa5dcffb152", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = plba.control.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C4_SEMANTIC_ROLES": "vector", - "C3_ENTRYPOINTS": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C4_SEMANTIC_ROLES": 12, - "C3_ENTRYPOINTS": 8, - "C2_DEPENDENCY_GRAPH": 8, - "C1_SYMBOL_CATALOG": 6, - "C0_SOURCE_CHUNKS": 4 - }, - "filters_by_layer": { - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 35, - "C3_ENTRYPOINTS": 21, - "C2_DEPENDENCY_GRAPH": 65, - "C1_SYMBOL_CATALOG": 27, - "C0_SOURCE_CHUNKS": 17 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start calls asyncio.run", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:calls", - "span_start": 22, - "span_end": 22, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", - "edge_type": "calls", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "asyncio.run", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.start:reads_attr", - "span_start": 20, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", - "edge_type": "reads_attr", - "src_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "src_qname": "ControlPlaneService.start", - "dst_symbol_id": null, - "dst_ref": "ControlPlaneService._channels", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "3030804d119fa1d4b8a6c32616062a5e11080b03d33818c9280bcc5bdd8fd512", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bd7f620031a049b8d791534536941ce75071029542395a7bb14817742827070a", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService\nControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "qname": "ControlPlaneService", - "kind": "class", - "signature": "ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = plba.control.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "90b154d49d544efb7c448e91bf5b75231578a6571b98c06a2a555fa5dcffb152", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = plba.control.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md deleted file mode 100644 index 0543d0f..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-architecture-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в ControlPlaneService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "В архитектуре подсистемы ControlPlaneService участвуют следующие основные компоненты:\n\n1. **ControlPlaneService** – главный сервис, инициализирующий и управляющий каналами контроля. Он создает каналы, регистрирует их и управляет жизненным циклом через методы `register_channel`, `start` и `stop`.\n - Создаёт экземпляры каналов (`ControlChannel`) и сохраняет их в поле `_channels`.\n - Вызывает асинхронную инициализацию каналов с помощью методов `start` и `stop`.\n\n2. **ControlChannel** – абстрактный базовый класс для каналов управления, определяющий интерфейс для старта и остановки канала.\n - Описывает абстракции для начала работы канала и освобождения ресурсов при завершении.\n\n3. **ControlActionSet** – модель действий, используемых в канале управления.\n\nСвязи между компонентами реализованы следующим образом:\n- **ControlPlaneService** создаёт и регистрирует экземпляры каналов управления через метод `register_channel`.\n- Каналы управления (например, HttpControlChannel) используют общий интерфейс `ControlChannel` для реализации своих функций старта и завершения.\n\nГраницы ответственности включают управление жизненным циклом каналов и координацию взаимодействия различных компонентов через зарегистрированные каналы.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md deleted file mode 100644 index 0d551a8..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-architecture-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в RuntimeManager? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "В подсистеме RuntimeManager участвуют следующие компоненты:\n\n1. **RuntimeManager** (src/app_runtime/core/runtime.py):\n - Инициализирует конфигурацию и управляет жизненным циклом runtime-пipeline.\n - Создаёт и регистрирует основные сервисы (ControlPlaneService, WorkflowPersistence, InMemoryTaskQueue, ConfigFileLoader, TraceContextStore, WorkerSupervisor).\n\n2. **ControlPlaneService** (src/app_runtime/control/service.py):\n - Служба управления каналами контроля и взаимодействия с внешними сущностями.\n - Регистрирует каналы и запускает асинхронные операции.\n\n3. **WorkflowPersistence** (src/app_runtime/workflow/persistence/workflow_persistence.py):\n - Обеспечивает долговременное хранение workflow-данных.\n\n4. **InMemoryTaskQueue** (src/app_runtime/queue/in_memory.py):\n - Хранит задачи в памяти для временного хранения и обработки.\n\n5. **ConfigFileLoader** (src/app_runtime/config/file_loader.py):\n - Загружает конфигурации из файлов.\n\n6. **TraceContextStore** (src/app_runtime/tracing/store.py):\n - Управляет контекстом трассировки.\n\n7. **WorkerSupervisor** (src/app_runtime/workers/supervisor.py):\n - Контролирует выполнение рабочих задач.\n\nЭти компоненты взаимодействуют через конструктор RuntimeManager, где регистрируются необходимые сервисы и каналы. Управление жизненным циклом и координация работы осуществляется через инициализацию и регистрацию сервисов.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json deleted file mode 100644 index 49a2b69..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json +++ /dev/null @@ -1,3779 +0,0 @@ -{ - "case_id": "plba-v2-explain-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Что делает функция create_runtime?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Функция `create_runtime` находится в файле `src/plba/bootstrap.py`. Она принимает аргумент `module`, представляющий экземпляр интерфейса `ApplicationModule`.\n\nПодтвержденные действия функции:\n- Инициализирует объект типа `RuntimeManager`.\n- Если указан путь к конфигурационному файлу (`config_path`), добавляет этот файл в менеджер конфигурации.\n- При включённой опции HTTP-контроля регистрирует канал управления через класс `HttpControlChannel`.\n- Регистрирует переданный модуль в менеджере.\n\nТаким образом, основная задача функции – создать и настроить базовый runtime для приложения.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Что делает функция create_runtime?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Что делает функция create_runtime?", - "normalized": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "function", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 19, - "end": 33 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "функция", - "source": "user_text", - "subtype": null, - "span": { - "start": 11, - "end": 18 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "create_runtime" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "create_runtime" - ], - "symbol_candidates": [ - "create_runtime" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Что делает функция create_runtime?", - "normalized": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "function", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 19, - "end": 33 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "функция", - "source": "user_text", - "subtype": null, - "span": { - "start": 11, - "end": 18 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "create_runtime", - "annotations", - "json", - "Path", - "Any", - "yaml", - "hashlib" - ], - "resolved_symbol": "create_runtime", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/plba/bootstrap.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/config/__init__.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/contracts/application.py", - "src/app_runtime/__init__.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/queue/in_memory.py", - "src/app_runtime/workers/supervisor.py", - "src/app_runtime/workflow/engine/workflow_engine.py", - "src/app_runtime/tracing/store.py", - "src/app_runtime/control/http_app.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "create_runtime", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "create_runtime", - "content": "function create_runtime\ncreate_runtime(module)", - "start_line": 8, - "end_line": 29, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "annotations", - "content": "const annotations\nannotations = __future__.annotations", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "json", - "content": "const json\nimport json", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Path", - "content": "const Path\nPath = pathlib.Path", - "start_line": 5, - "end_line": 5, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Any", - "content": "const Any\nAny = typing.Any", - "start_line": 6, - "end_line": 6, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "yaml", - "content": "const yaml\nimport yaml", - "start_line": 8, - "end_line": 8, - "metadata": { - "symbol_id": "223502bbfc2b82aea662f7466403cc99a3cd44f1b0507d637cd674874f751e4f", - "qname": "yaml", - "kind": "const", - "signature": "import yaml", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "hashlib", - "content": "const hashlib\nimport hashlib", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/bootstrap.py", - "title": "src/plba/bootstrap.py:create_runtime", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "start_line": 8, - "end_line": 29, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/__init__.py", - "title": "src/app_runtime/config/__init__.py:1-4", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/file_loader.py", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "start_line": 11, - "end_line": 48, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/application.py", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "start_line": 8, - "end_line": 16, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/config/file_loader.py", - "title": "ConfigFileLoader", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "start_line": 11, - "end_line": 48, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workers/supervisor.py", - "title": "WorkerSupervisor", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 59, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "title": "WorkflowEngine", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 10, - "end_line": 86, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/tracing/store.py", - "title": "TraceContextStore", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "start_line": 15, - "end_line": 52, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:instantiates", - "content": "create_runtime instantiates RuntimeManager", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.control_plane.register_channel", - "start_line": 21, - "end_line": 27, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.add_config_file" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime instantiates RuntimeManager" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.control_plane.register_channel" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.add_config_file" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const yaml\nimport yaml", - "layer": "C1_SYMBOL_CATALOG", - "title": "yaml", - "span_start": 8, - "span_end": 8, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "223502bbfc2b82aea662f7466403cc99a3cd44f1b0507d637cd674874f751e4f", - "qname": "yaml", - "kind": "const", - "signature": "import yaml", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 33, - "C0_SOURCE_CHUNKS": 15, - "C4_SEMANTIC_ROLES": 15, - "C2_DEPENDENCY_GRAPH": 44, - "C3_ENTRYPOINTS": 10 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const yaml\nimport yaml", - "layer": "C1_SYMBOL_CATALOG", - "title": "yaml", - "span_start": 8, - "span_end": 8, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "223502bbfc2b82aea662f7466403cc99a3cd44f1b0507d637cd674874f751e4f", - "qname": "yaml", - "kind": "const", - "signature": "import yaml", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 23, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "a8474eca8b6e9dc86ae67ed68b16fa5fb639ef08739c053e7b7195489765667f", - "symbol_name": "ConfigFileLoader", - "qname": "ConfigFileLoader", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 8, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workers/supervisor.py", - "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkerSupervisor", - "span_start": 10, - "span_end": 59, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "c17b44e8d9e97d490989b21fa67d7c346cdda8a0472e4c41fb243c8846faa124", - "symbol_name": "WorkerSupervisor", - "qname": "WorkerSupervisor", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "77609d9d5927171cce7fc3a54897c183fd63068710c6362029b700937aae5eee", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/engine/workflow_engine.py", - "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowEngine", - "span_start": 10, - "span_end": 86, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "57ec0a9f11c542c78e008684a888397e8d9ef4223671acb2567e631a0cbc70b4", - "symbol_name": "WorkflowEngine", - "qname": "WorkflowEngine", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1057136e58a325cd5ab6f4e265d15665fb6a711b7022d9fab52a1a290afa2368", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/tracing/store.py", - "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)", - "layer": "C4_SEMANTIC_ROLES", - "title": "TraceContextStore", - "span_start": 15, - "span_end": 52, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 25, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b2dad4fbe16ffb11b58deba311c7739955c39d59f291b22181f33e9c8cce4059", - "symbol_name": "TraceContextStore", - "qname": "TraceContextStore", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 6, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "d369554f08fc92039c6edd5a2a1e73b23901533e8974459170bbd9347d263dc5", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md deleted file mode 100644 index d3586a5..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Что делает функция create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Функция `create_runtime` находится в файле `src/plba/bootstrap.py`. Она принимает аргумент `module`, представляющий экземпляр интерфейса `ApplicationModule`.\n\nПодтвержденные действия функции:\n- Инициализирует объект типа `RuntimeManager`.\n- Если указан путь к конфигурационному файлу (`config_path`), добавляет этот файл в менеджер конфигурации.\n- При включённой опции HTTP-контроля регистрирует канал управления через класс `HttpControlChannel`.\n- Регистрирует переданный модуль в менеджере.\n\nТаким образом, основная задача функции – создать и настроить базовый runtime для приложения.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md deleted file mode 100644 index 87e3b4b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-local-http-channel - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN_LOCAL", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` в файле `http_channel.py` реализует канал управления для HTTP-запросов. В конструкторе (`__init__`) создаются основные компоненты:\n\n- `_runner`: объект типа `UvicornThreadRunner`, управляющий асинхронным сервером uvicorn.\n- `_factory`: фабрика приложений типа `HttpControlAppFactory`, создающая приложения для обработки запросов.\n- `_actions`: коллекция действий управления, инициализируется как `None`.\n\nМетод `start` запускает сервер с приложением, созданным фабрикой, и ожидает завершения работы сервера при вызове `stop`. Класс предназначен для организации взаимодействия с внешним миром через HTTP-интерфейсы.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "symbol_candidates": [ - "HttpControlChannel" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json deleted file mode 100644 index 83d2c9a..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json +++ /dev/null @@ -1,4092 +0,0 @@ -{ - "case_id": "plba-v2-explain-nonexistent-symbol", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Объясни класс RuntimeFactoryManager", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeFactoryManager` не найден в предоставленном контексте. \n\nСогласно имеющимся данным, наиболее близкой сущностью является `ControlChannel`, объявленный в файле `base.py`. Однако его описание и работа напрямую не связаны с созданием или управлением фабриками для runtime. Если предполагается наличие класса с таким названием, возможно, он описан в другом модуле или импортируется из внешнего пакета. Рекомендую проверить остальные части проекта или уточнить местоположение данного класса.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": false, - "mismatches": [ - "answer_mode: expected degraded, got answered", - "retrieval: expected empty rag, got 33 rows", - "llm: expected answer to contain 'не найдена'" - ], - "details": { - "query": "Объясни класс RuntimeFactoryManager", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Объясни класс RuntimeFactoryManager", - "normalized": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeFactoryManager" - ], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeFactoryManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 35 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 8, - "end": 13 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeFactoryManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Объясни класс RuntimeFactoryManager", - "normalized": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeFactoryManager" - ], - "keyword_hints": [ - "RuntimeFactoryManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeFactoryManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 35 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 8, - "end": 13 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "ControlChannel", - "ControlChannel.stop", - "ControlActionSet", - "ControlPlaneService", - "ControlChannel.start" - ], - "resolved_symbol": null, - "symbol_resolution_status": "ambiguous", - "file_candidates": [ - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/service.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_app.py", - "src/plba/control.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py", - "src/app_runtime/queue/in_memory.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "class ControlChannel\nControlChannel(ABC)", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.stop", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "start_line": 27, - "end_line": 28, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "class ControlActionSet\nControlActionSet", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlChannel", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.start", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "start_line": 23, - "end_line": 24, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/http_channel.py", - "title": "ControlActionSet", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/control.py", - "title": "src/plba/control.py:1-10", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "start_line": 1, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/queue/in_memory.py", - "title": "InMemoryTaskQueue", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "start_line": 9, - "end_line": 38, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.register_channel:reads_attr", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.register_channel reads_attr self._channels.append" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel\nControlChannel(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 64, - "C0_SOURCE_CHUNKS": 24, - "C4_SEMANTIC_ROLES": 16, - "C2_DEPENDENCY_GRAPH": 56, - "C3_ENTRYPOINTS": 12 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни класс RuntimeFactoryManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel\nControlChannel(ABC)", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "qname": "ControlChannel", - "kind": "class", - "signature": "ControlChannel(ABC)", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet\nControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "qname": "ControlActionSet", - "kind": "class", - "signature": "ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlChannel\nControlChannel = app_runtime.control.base.ControlChannel", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "268420f7aa4ed74082b9276cae0cded4f00bac090ffd58fa020a65be0fe19c27", - "qname": "ControlChannel", - "kind": "const", - "signature": "ControlChannel = app_runtime.control.base.ControlChannel", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 1, - "span_end": 1, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "767e4ac0d4224aeccb0783a38359d3c03899a876736eb83d99887c16ea07cc6c", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "const ControlActionSet\nControlActionSet = app_runtime.control.base.ControlActionSet", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlActionSet", - "span_start": 7, - "span_end": 7, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "2132a5717c57061e3488a1bf4d43650a60ea903a42278f4d494c014bc80d2df9", - "qname": "ControlActionSet", - "kind": "const", - "signature": "ControlActionSet = app_runtime.control.base.ControlActionSet", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/queue/in_memory.py", - "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)", - "layer": "C4_SEMANTIC_ROLES", - "title": "InMemoryTaskQueue", - "span_start": 9, - "span_end": 38, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 22, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "2da04cb94544a3bcbf0943a95ad4bdd8710bcafaa32a02fd0e4de2178dcf3533", - "symbol_name": "InMemoryTaskQueue", - "qname": "InMemoryTaskQueue", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 9, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "58f0cc001ccda0eee4c6bc32ed83bd05eafd6b6644f1e8b4aa9eed3103db73dc", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.register_channel reads_attr self._channels.append", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.register_channel:reads_attr", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "1ee5925deffdc38ba15b88bf7c89e5fcd1a78f493fe30f2deb827d714a1b18e8", - "edge_type": "reads_attr", - "src_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "src_qname": "ControlPlaneService.register_channel", - "dst_symbol_id": null, - "dst_ref": "self._channels.append", - "resolution": "partial", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md deleted file mode 100644 index 8858984..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md +++ /dev/null @@ -1,36 +0,0 @@ -# plba-v2-explain-nonexistent-symbol - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Объясни класс RuntimeFactoryManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeFactoryManager` не найден в предоставленном контексте. \n\nСогласно имеющимся данным, наиболее близкой сущностью является `ControlChannel`, объявленный в файле `base.py`. Однако его описание и работа напрямую не связаны с созданием или управлением фабриками для runtime. Если предполагается наличие класса с таким названием, возможно, он описан в другом модуле или импортируется из внешнего пакета. Рекомендую проверить остальные части проекта или уточнить местоположение данного класса.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeFactoryManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- answer_mode: expected degraded, got answered -- retrieval: expected empty rag, got 33 rows -- llm: expected answer to contain 'не найдена' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json deleted file mode 100644 index 40431cb..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json +++ /dev/null @@ -1,4154 +0,0 @@ -{ - "case_id": "plba-v2-explain-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Объясни как работает класс RuntimeManager", - "actual": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeManager` определен в файле `src/app_runtime/core/runtime.py`, начиная с строки 18. Из доступных контекстных данных напрямую невозможно точно описать его работу, так как отсутствует подробная реализация или вызовы этого класса.\n\nТем не менее, можно сделать осторожные выводы:\n\n- Класс играет роль менеджера и управляет состоянием выполнения приложения.\n- Вероятно, он участвует в координации различных компонентов и служб через атрибуты и методы, такие как чтение и запись состояния (`configuration`, `add_config_file`), а также участие в срезах данных потока выполнения (`participates in dataflow slices`).\n- На основании имеющихся свидетельств сложно точно понять, какие конкретно действия выполняет этот класс при инициализации и во время своей работы.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Объясни как работает класс RuntimeManager", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Объясни как работает класс RuntimeManager", - "normalized": "Объясни как работает класс RuntimeManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 27, - "end": 41 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 21, - "end": 26 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "RuntimeManager" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс RuntimeManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "keyword_hints": [ - "RuntimeManager" - ], - "symbol_candidates": [ - "RuntimeManager" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 8 - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Объясни как работает класс RuntimeManager", - "normalized": "Объясни как работает класс RuntimeManager", - "sub_intent": "EXPLAIN", - "negations": [], - "expansions": [ - "RuntimeManager" - ], - "keyword_hints": [ - "RuntimeManager" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "RuntimeManager", - "source": "user_text", - "subtype": null, - "span": { - "start": 27, - "end": 41 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "класс", - "source": "user_text", - "subtype": null, - "span": { - "start": 21, - "end": 26 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "RuntimeManager", - "ControlPlaneService", - "ControlChannel.start", - "ControlChannel.stop" - ], - "resolved_symbol": "RuntimeManager", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/bootstrap.py", - "src/app_runtime/control/service.py", - "src/app_runtime/core/runtime.py", - "src/plba/__init__.py", - "src/plba/core.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/http_runner.py", - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_channel.py", - "src/plba/control.py", - "src/app_runtime/workflow/persistence/workflow_persistence.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/service.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 9, - "end_line": 9, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "class RuntimeManager\nRuntimeManager", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "start_line": 16, - "end_line": 16, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/core.py", - "title": "RuntimeManager", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/__init__.py", - "title": "ControlPlaneService", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.start", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "start_line": 23, - "end_line": 24, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel.stop", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "start_line": 27, - "end_line": 28, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/service.py", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "start_line": 12, - "end_line": 52, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/control.py", - "title": "src/plba/control.py:1-10", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "start_line": 1, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "start_line": 18, - "end_line": 179, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlChannel", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 21, - "end_line": 28, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/base.py", - "title": "ControlActionSet", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "start_line": 14, - "end_line": 18, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "start_line": 12, - "end_line": 52, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_runner.py", - "title": "UvicornThreadRunner", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "start_line": 10, - "end_line": 61, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_channel.py", - "title": "HttpControlChannel", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "start_line": 12, - "end_line": 57, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/control/http_app.py", - "title": "HttpControlAppFactory", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "start_line": 15, - "end_line": 53, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C4_SEMANTIC_ROLES", - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "title": "WorkflowPersistence", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "start_line": 8, - "end_line": 54, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "start_line": 14, - "end_line": 25, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "start_line": 14, - "end_line": 51, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "start_line": 14, - "end_line": 17, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "start_line": 14, - "end_line": 20, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/control/service.py", - "title": "ControlPlaneService.__init__:dataflow_slice", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "start_line": 14, - "end_line": 47, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/core/runtime.py", - "title": "RuntimeManager.__init__:dataflow_slice", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "start_line": 32, - "end_line": 52, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start" - }, - { - "path": "src/app_runtime/control/service.py", - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async" - }, - { - "path": "src/app_runtime/core/runtime.py", - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" - } - ], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "layer": "C4_SEMANTIC_ROLES", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 43, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": null, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 46, - "C0_SOURCE_CHUNKS": 17, - "C4_SEMANTIC_ROLES": 16, - "C2_DEPENDENCY_GRAPH": 56, - "C3_ENTRYPOINTS": 11 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс RuntimeManager", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/bootstrap.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 4, - "span_end": 4, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 9, - "span_end": 9, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "62a9575c77aad894120d18b4f2a08cf2ba42f77e9be4a8a432b767d157701afe", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "class RuntimeManager\nRuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "qname": "RuntimeManager", - "kind": "class", - "signature": "RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.core.runtime", - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "const RuntimeManager\nRuntimeManager = plba.core.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 16, - "span_end": 16, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "7eacec84f9b8d6c4201374591faecdac7493091c263681495c338973f2971ad9", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = plba.core.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/core.py", - "content": "const RuntimeManager\nRuntimeManager = app_runtime.core.runtime.RuntimeManager", - "layer": "C1_SYMBOL_CATALOG", - "title": "RuntimeManager", - "span_start": 2, - "span_end": 2, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e1684562d978b7af7fe9b27dc5869d770348a87b5dc19a50360f58544668578b", - "qname": "RuntimeManager", - "kind": "const", - "signature": "RuntimeManager = app_runtime.core.runtime.RuntimeManager", - "parent_symbol_id": null, - "package_or_module": "src.plba.core", - "is_test": false, - "blob_sha": "c0ae25110d20e665216616e26b68adfe035b624ba45d31d1272fb21f906f9ca8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "const ControlPlaneService\nControlPlaneService = app_runtime.control.service.ControlPlaneService", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlPlaneService", - "span_start": 3, - "span_end": 3, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "217e8f044d1c01644bf7b81e5046af9e84469210c692a2fb0c476a19bb069ae1", - "qname": "ControlPlaneService", - "kind": "const", - "signature": "ControlPlaneService = app_runtime.control.service.ControlPlaneService", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.start\nstart(self, actions)\nStart the control channel and bind handlers.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.start", - "span_start": 23, - "span_end": 24, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e01e0d50d0f48d0c84c119c989b7a7c57ceea263811ce2605c684ae24d1a03b1", - "qname": "ControlChannel.start", - "kind": "method", - "signature": "start(self, actions)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "method ControlChannel.stop\nstop(self)\nStop the control channel and release resources.", - "layer": "C1_SYMBOL_CATALOG", - "title": "ControlChannel.stop", - "span_start": 27, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "54b5adf9866c526836221dc721b474ba23fbec83e1b1d3b8bc4da67ae3c1541d", - "qname": "ControlChannel.stop", - "kind": "method", - "signature": "stop(self)", - "parent_symbol_id": "ControlChannel", - "package_or_module": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "class ControlPlaneService:\n def __init__(self) -> None:\n self._channels: list[ControlChannel] = []\n\n def register_channel(self, channel: ControlChannel) -> None:\n self._channels.append(channel)\n\n def start(self, runtime: RuntimeManager) -> None:\n if not self._channels:\n return\n asyncio.run(self._start_async(runtime))\n\n def stop(self) -> None:\n if not self._channels:\n return\n asyncio.run(self._stop_async())\n\n def snapshot(self, runtime: RuntimeManager) -> dict[str, object]:\n health = runtime.current_health()\n return {\n \"runtime\": {\"state\": runtime._state.value},\n \"modules\": list(runtime.registry.modules),\n \"services\": runtime.services.snapshot(),\n \"workers\": runtime.workers.snapshot(),\n \"health\": runtime.health.snapshot(runtime.workers.healths()) | {\"status\": health[\"status\"]},\n \"config\": runtime.configuration.get(),\n }\n\n async def _start_async(self, runtime: RuntimeManager) -> None:\n actions = ControlActionSet(\n health=runtime.health_status,\n start=runtime.start_runtime,\n stop=runtime.stop_runtime,\n status=runtime.runtime_status,\n )\n for channel in self._channels:\n await channel.start(actions)\n\n async def _stop_async(self) -> None:\n for channel in reversed(self._channels):\n await channel.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/service.py:ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.service", - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/control.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"HttpControlChannel\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/control.py:1-10", - "span_start": 1, - "span_end": 10, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.control", - "is_test": false, - "blob_sha": "31bd5c4481bfa7fbca8fae56d4860a67e3953ca74474ac8439e1f39b685d7bc8", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)", - "layer": "C4_SEMANTIC_ROLES", - "title": "RuntimeManager", - "span_start": 18, - "span_end": 179, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 43, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7e4a9381328c5803bbc6179458612fc4e947d928aa7bf8b4b2bebb2c8592f758", - "symbol_name": "RuntimeManager", - "qname": "RuntimeManager", - "role": "pipeline_stage", - "confidence": 0.67, - "dataflow_participation": 50, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "cfcfe9a311d3a2dbdaf32ac4ccd73c0eb9a117f830591a1c0867ee97d46204ff", - "symbol_name": "ControlChannel", - "qname": "ControlChannel", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 40, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "46eb026cb3313415ec47b82dd22f84f4d112c9d987e8b1716dcb0baa1cce8988", - "symbol_name": "ControlActionSet", - "qname": "ControlActionSet", - "role": "model", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)", - "layer": "C4_SEMANTIC_ROLES", - "title": "ControlPlaneService", - "span_start": 12, - "span_end": 52, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 68, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "b13471e5916986dccffb53fab613812842965705e6b3a89ae549d30c9e91e9aa", - "symbol_name": "ControlPlaneService", - "qname": "ControlPlaneService", - "role": "pipeline_stage", - "confidence": 0.57, - "dataflow_participation": 5, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)", - "layer": "C4_SEMANTIC_ROLES", - "title": "UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 11, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "fd55630045a02100df8877ac27d951ee08617d4598764394d48cb51fe067476a", - "symbol_name": "UvicornThreadRunner", - "qname": "UvicornThreadRunner", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 24, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 21, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "1c9fbdc24819e5604c26ea55428a74310f03a03e1af197ed84846af61e42fdb0", - "symbol_name": "HttpControlChannel", - "qname": "HttpControlChannel", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 10, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory", - "layer": "C4_SEMANTIC_ROLES", - "title": "HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 39, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "9b3502a5fb408b273223db13264349cf500de24915b6c649d9ea8970d0dfd8e0", - "symbol_name": "HttpControlAppFactory", - "qname": "HttpControlAppFactory", - "role": "factory", - "confidence": 0.99, - "dataflow_participation": 0, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", - "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)", - "layer": "C4_SEMANTIC_ROLES", - "title": "WorkflowPersistence", - "span_start": 8, - "span_end": 54, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 15, - "layer_rank": 2, - "distance": NaN, - "metadata": { - "symbol_id": "7bd01ee45cf31f2d5c2e3e51656254860ac785d10cef9e0852cd4fba90857bae", - "symbol_name": "WorkflowPersistence", - "qname": "WorkflowPersistence", - "role": "pipeline_stage", - "confidence": 0.99, - "dataflow_participation": 16, - "execution_trace_proximity": 0, - "is_test": false, - "blob_sha": "80e9410ddc639789b4353c2a1a757ba8d0d5b5bb6075b0b263b61551f04ae1f0", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.stop", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 25, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d", - "dst_ref": "ControlPlaneService.stop", - "resolution": "resolved", - "slice_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.stop" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "bd50ae61353169acb2967a7085411ff58dfaa2e125e79ff1a42697add7380d0d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._stop_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 51, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a", - "dst_ref": "ControlPlaneService._stop_async", - "resolution": "resolved", - "slice_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._stop_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "f3b9abaed413133f25c01074948db3fc551540fd2f8b7ba7bfdb1c59bd0a748a" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957", - "dst_ref": "ControlPlaneService.register_channel", - "resolution": "resolved", - "slice_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.register_channel" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b0313a9161dec8d8ad803adcde0cb082c57806e0a3edcd3dd40f8ed1a09b0957" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService.start", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 20, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154", - "dst_ref": "ControlPlaneService.start", - "resolution": "resolved", - "slice_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService.start" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "8f9aa720eb89aaf78c914c2a96e1b07bc0699eb666b51e332fc5f467f6f44154" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/service.py", - "content": "ControlPlaneService.__init__\n -> ControlPlaneService._channels\n -> ControlPlaneService._start_async", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "ControlPlaneService.__init__:dataflow_slice", - "span_start": 14, - "span_end": 47, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "edge_type": "dataflow_slice", - "src_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "src_qname": "ControlPlaneService.__init__", - "dst_symbol_id": "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517", - "dst_ref": "ControlPlaneService._start_async", - "resolution": "resolved", - "slice_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", - "root_symbol_id": "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "path_symbols": [ - "ControlPlaneService.__init__", - "ControlPlaneService._channels", - "ControlPlaneService._start_async" - ], - "path_symbol_ids": [ - "d8008ee40e320f4551179bed7a3665a5e7d65850412051bcdf86007fa25f717a", - "b1a6eb93235bdad207d2bac24162aa65d662725b833b73e145b7f7fc3ecf9517" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "f53bb9e39148f37ecabad38b290219ae5bc562b9eb07fcd9965f5770fa3d6594", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/core/runtime.py", - "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "RuntimeManager.__init__:dataflow_slice", - "span_start": 32, - "span_end": 52, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "edge_type": "dataflow_slice", - "src_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "src_qname": "RuntimeManager.__init__", - "dst_symbol_id": "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d", - "dst_ref": "RuntimeManager.add_config_file", - "resolution": "resolved", - "slice_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", - "root_symbol_id": "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "path_symbols": [ - "RuntimeManager.__init__", - "RuntimeManager.configuration", - "RuntimeManager.add_config_file" - ], - "path_symbol_ids": [ - "0bd33af01139de711a34193394772f481224acf06d96055f935e259d9bcc4a05", - "57ffbd4f0d9fdf3507c2b8624312ce211f3d02fdf86a57a8ec90778d8a7b498d" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "e16bb7231eb419d6d069a62767cfe7ac7a2acfc4cd1e34e65907f3456623aa68", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md deleted file mode 100644 index 8bae42c..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Объясни как работает класс RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeManager` определен в файле `src/app_runtime/core/runtime.py`, начиная с строки 18. Из доступных контекстных данных напрямую невозможно точно описать его работу, так как отсутствует подробная реализация или вызовы этого класса.\n\nТем не менее, можно сделать осторожные выводы:\n\n- Класс играет роль менеджера и управляет состоянием выполнения приложения.\n- Вероятно, он участвует в координации различных компонентов и служб через атрибуты и методы, такие как чтение и запись состояния (`configuration`, `add_config_file`), а также участие в срезах данных потока выполнения (`participates in dataflow slices`).\n- На основании имеющихся свидетельств сложно точно понять, какие конкретно действия выполняет этот класс при инициализации и во время своей работы.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md deleted file mode 100644 index 4786f23..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-explain-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Объясни как работает класс TraceService - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Это сервис для управления контекстами трассировки и записи событий в журнал.\n\nЕго основные обязанности:\n- Инициализация сервиса при создании экземпляра (`__init__`) с передачей транспортов и хранилищ контекста.\n- Создание нового контекста трассировки через метод `create_context`, который генерирует уникальный идентификатор трассировки и сохраняет запись контекста в хранилище.\n- Предоставление текущего идентификатора трассировки через метод `current_trace_id`.\n\nКонструктор принимает два необязательных параметра:\n- `transport`: транспорт для отправки сообщений трассировки (по умолчанию используется `NoOpTraceTransport`).\n- `store`: хранилище контекста (по умолчанию используется `TraceContextStore`).\n\nТаким образом, `TraceService` играет ключевую роль в отслеживании и документировании событий приложения, обеспечивая единообразие логирования и мониторинга.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json deleted file mode 100644 index d3d2afd..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json +++ /dev/null @@ -1,1303 +0,0 @@ -{ - "case_id": "plba-v2-find-entrypoints-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Найди точки входа HTTP control plane", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Подтверждённые HTTP route points:\n\n- GET /health (src/app_runtime/control/http_app.py:52)\n- POST (не указан конкретный путь, но находится в src/app_runtime/control/http_app.py:38-42)\n- GET (повтор, src/app_runtime/control/http_app.py:38-42)\n\nКандидат на точку входа без явного HTTP route маркера:\n- Класс HttpControlChannel в src/app_runtime/control/http_channel.py:12-57, хотя его прямая роль неясна без дополнительного анализа поведения методов start и stop.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Найди точки входа HTTP control plane", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Найди точки входа HTTP control plane", - "normalized": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "negations": [], - "expansions": [ - "HTTP", - "control", - "plane" - ], - "keyword_hints": [ - "HTTP", - "control", - "plane" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "HTTP", - "source": "user_text", - "subtype": null, - "span": { - "start": 18, - "end": 22 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "control", - "source": "user_text", - "subtype": null, - "span": { - "start": 23, - "end": 30 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "plane", - "source": "user_text", - "subtype": null, - "span": { - "start": 31, - "end": 36 - }, - "confidence": 0.88 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 12 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "HTTP", - "control", - "plane" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "keyword_hints": [ - "HTTP", - "control", - "plane" - ], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C3_ENTRYPOINTS", - "top_k": 12 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 6 - } - ], - "filters": { - "test_policy": "EXCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**" - ], - "exclude_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "prefer_globs": [], - "test_file_globs": [], - "test_symbol_patterns": [], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Найди точки входа HTTP control plane", - "normalized": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "negations": [], - "expansions": [ - "HTTP", - "control", - "plane" - ], - "keyword_hints": [ - "HTTP", - "control", - "plane" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "HTTP", - "source": "user_text", - "subtype": null, - "span": { - "start": 18, - "end": 22 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "control", - "source": "user_text", - "subtype": null, - "span": { - "start": 23, - "end": 30 - }, - "confidence": 0.88 - }, - { - "type": "SYMBOL", - "value": "plane", - "source": "user_text", - "subtype": null, - "span": { - "start": 31, - "end": 36 - }, - "confidence": 0.88 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [], - "resolved_symbol": null, - "symbol_resolution_status": "not_found", - "file_candidates": [ - "src/app_runtime/control/http_app.py", - "src/app_runtime/control/http_channel.py", - "src/app_runtime/control/base.py", - "src/app_runtime/control/__init__.py", - "src/app_runtime/control/http_runner.py" - ], - "code_chunks": [ - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "content": "fastapi http app.post", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 31, - "end_line": 34, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C3_ENTRYPOINTS", - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "content": "fastapi http app.get", - "start_line": 38, - "end_line": 42, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_channel.py", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "start_line": 12, - "end_line": 57, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_app.py", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "start_line": 15, - "end_line": 53, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "start_line": 14, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/__init__.py", - "title": "src/app_runtime/control/__init__.py:1-5", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "start_line": 1, - "end_line": 5, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/base.py", - "title": "src/app_runtime/control/base.py:ControlChannel", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "start_line": 21, - "end_line": 28, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/control/http_runner.py", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "start_line": 10, - "end_line": 61, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [], - "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.get", - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": null, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 - }, - "filters_by_layer": { - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 14, - "C0_SOURCE_CHUNKS": 17 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 9 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.post", - "layer": "C3_ENTRYPOINTS", - "title": "app.post", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 31, - "span_end": 34, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "fastapi http app.get", - "layer": "C3_ENTRYPOINTS", - "title": "app.get", - "span_start": 38, - "span_end": 42, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 0, - "distance": NaN, - "metadata": { - "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.get", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "GET" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_channel.py", - "content": "class HttpControlChannel(ControlChannel):\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._timeout = timeout\n self._runner = UvicornThreadRunner(host, port, timeout)\n self._factory = HttpControlAppFactory()\n self._actions: ControlActionSet | None = None\n\n async def start(self, actions: ControlActionSet) -> None:\n self._actions = actions\n app = self._factory.create(self._health_response, self._action_response)\n await self._runner.start(app)\n\n async def stop(self) -> None:\n await self._runner.stop()\n\n @property\n def port(self) -> int:\n return self._runner.port\n\n async def _health_response(self) -> dict[str, object]:\n if self._actions is None:\n return {\"status\": \"unhealthy\", \"detail\": \"control actions are not configured\"}\n return await asyncio.wait_for(self._actions.health(), timeout=float(self._timeout))\n\n async def _action_response(self, action: str, _client_source: str = \"unknown\") -> JSONResponse:\n if self._actions is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"{action} handler is not configured\"}, status_code=404)\n callbacks = {\n \"start\": self._actions.start,\n \"stop\": self._actions.stop,\n \"status\": self._actions.status,\n }\n callback = callbacks.get(action)\n if callback is None:\n return JSONResponse(content={\"status\": \"error\", \"detail\": f\"unsupported action: {action}\"}, status_code=404)\n action_timeout = max(float(self._timeout), 10.0) if action in {\"start\", \"stop\"} else float(self._timeout)\n try:\n detail = await asyncio.wait_for(callback(), timeout=action_timeout)\n except asyncio.TimeoutError:\n return JSONResponse(\n content={\"status\": \"accepted\", \"detail\": f\"{action} operation is still in progress\"},\n status_code=202,\n )\n except Exception as exc:\n return JSONResponse(content={\"status\": \"error\", \"detail\": str(exc)}, status_code=500)\n return JSONResponse(content={\"status\": \"ok\", \"detail\": detail or f\"{action} action accepted\"}, status_code=200)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_channel.py:HttpControlChannel", - "span_start": 12, - "span_end": 57, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_channel", - "is_test": false, - "blob_sha": "286e9615e209bc395ce9db0cd70f2236012e3e86b0257dc87e215e01f7f89ada", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_app.py", - "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", - "span_start": 15, - "span_end": 53, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_app", - "is_test": false, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlActionSet:\n health: HealthHandler\n start: ActionHandler\n stop: ActionHandler\n status: ActionHandler", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlActionSet", - "span_start": 14, - "span_end": 18, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/__init__.py", - "content": "from app_runtime.control.base import ControlActionSet, ControlChannel\nfrom app_runtime.control.http_channel import HttpControlChannel\nfrom app_runtime.control.service import ControlPlaneService\n\n__all__ = [\"ControlActionSet\", \"ControlChannel\", \"ControlPlaneService\", \"HttpControlChannel\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/__init__.py:1-5", - "span_start": 1, - "span_end": 5, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.control.__init__", - "is_test": false, - "blob_sha": "bf3c37e3369a84cc618adc0fd71c232e5eb4b871eaff743069a17e661e498316", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/base.py", - "content": "class ControlChannel(ABC):\n @abstractmethod\n async def start(self, actions: ControlActionSet) -> None:\n \"\"\"Start the control channel and bind handlers.\"\"\"\n\n @abstractmethod\n async def stop(self) -> None:\n \"\"\"Stop the control channel and release resources.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/base.py:ControlChannel", - "span_start": 21, - "span_end": 28, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 1, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.base", - "is_test": false, - "blob_sha": "84754bc651a3d90eed09f74a53d7df9a02fa15657e4773a6cc840bd3bed134b7", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/control/http_runner.py", - "content": "class UvicornThreadRunner:\n def __init__(self, host: str, port: int, timeout: int) -> None:\n self._host = host\n self._port = port\n self._timeout = timeout\n self._server: Server | None = None\n self._thread: Thread | None = None\n self._error: BaseException | None = None\n\n async def start(self, app: FastAPI) -> None:\n if self._thread is not None and self._thread.is_alive():\n return\n self._error = None\n config = Config(app=app, host=self._host, port=self._port, log_level=\"warning\")\n self._server = Server(config)\n self._thread = Thread(target=self._serve, name=\"plba-http-control\", daemon=True)\n self._thread.start()\n await self._wait_until_started()\n\n async def stop(self) -> None:\n if self._server is None or self._thread is None:\n return\n self._server.should_exit = True\n await asyncio.to_thread(self._thread.join, self._timeout)\n self._server = None\n self._thread = None\n\n @property\n def port(self) -> int:\n if self._server is None or not getattr(self._server, \"servers\", None):\n return self._port\n socket = self._server.servers[0].sockets[0]\n return int(socket.getsockname()[1])\n\n async def _wait_until_started(self) -> None:\n if self._server is None:\n raise RuntimeError(\"Server is not initialized\")\n deadline = asyncio.get_running_loop().time() + max(float(self._timeout), 1.0)\n while not self._server.started:\n if self._error is not None:\n raise RuntimeError(\"HTTP control server failed to start\") from self._error\n if asyncio.get_running_loop().time() >= deadline:\n raise TimeoutError(\"HTTP control server startup timed out\")\n await asyncio.sleep(0.05)\n\n def _serve(self) -> None:\n if self._server is None:\n return\n try:\n asyncio.run(self._server.serve())\n except BaseException as exc: # noqa: BLE001\n self._error = exc", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/control/http_runner.py:UvicornThreadRunner", - "span_start": 10, - "span_end": 61, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.control.http_runner", - "is_test": false, - "blob_sha": "3779fdd2878b770e789a35bb2a89c9d79f13b61c26d7db1b3b683f9bb9e1623f", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md deleted file mode 100644 index 86db5f1..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md +++ /dev/null @@ -1,33 +0,0 @@ -# plba-v2-find-entrypoints-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Найди точки входа HTTP control plane - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Подтверждённые HTTP route points:\n\n- GET /health (src/app_runtime/control/http_app.py:52)\n- POST (не указан конкретный путь, но находится в src/app_runtime/control/http_app.py:38-42)\n- GET (повтор, src/app_runtime/control/http_app.py:38-42)\n\nКандидат на точку входа без явного HTTP route маркера:\n- Класс HttpControlChannel в src/app_runtime/control/http_channel.py:12-57, хотя его прямая роль неясна без дополнительного анализа поведения методов start и stop.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md deleted file mode 100644 index 108557a..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-entrypoints-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Где health endpoint? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Конкретный health endpoint не обнаружен напрямую.\n\nОднако подтверждённые HTTP routes:\n- GET / (объявлен в src/app_runtime/control/http_app.py:31-34)\n- POST / (объявлен в src/app_runtime/control/http_app.py:38-42)\n- GET / (повторное объявление в src/app_runtime/control/http_app.py:38-42)", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "endpoint" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- llm: expected answer to contain 'GET /health' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json deleted file mode 100644 index d7b55d8..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json +++ /dev/null @@ -1,2746 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для create_runtime?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Прямых тестов для `create_runtime` не обнаружено. Ближайший тест находится в файле `tests/test_runtime.py`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод `create_runtime`. Косвенное покрытие отсутствует.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для create_runtime?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для create_runtime?", - "normalized": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 28 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_create_runtime", - "Testcreate_runtime", - "create_runtime" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "create_runtime" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "create_runtime" - ], - "symbol_candidates": [ - "create_runtime" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_create_runtime", - "Testcreate_runtime", - "create_runtime" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для create_runtime?", - "normalized": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "create_runtime" - ], - "keyword_hints": [ - "create_runtime" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "create_runtime" - ], - "symbol_kind_hint": "function", - "anchors": [ - { - "type": "SYMBOL", - "value": "create_runtime", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 28 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "create_runtime", - "FileConfigProvider", - "hashlib", - "json", - "Path", - "Any", - "annotations" - ], - "resolved_symbol": "create_runtime", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/plba/bootstrap.py", - "src/app_runtime/config/__init__.py", - "src/app_runtime/config/file_loader.py", - "tests/test_runtime.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/contracts/config.py", - "src/app_runtime/contracts/health.py", - "src/app_runtime/contracts/application.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "create_runtime", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/bootstrap.py", - "title": "create_runtime", - "content": "function create_runtime\ncreate_runtime(module)", - "start_line": 8, - "end_line": 29, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/__init__.py", - "title": "FileConfigProvider", - "content": "const FileConfigProvider\nFileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "start_line": 2, - "end_line": 2, - "metadata": { - "symbol_id": "e449b19e5881889adeb6e056eafe1da30acbae864f06984ea2edc7c15f7cb6d6", - "qname": "FileConfigProvider", - "kind": "const", - "signature": "FileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "hashlib", - "content": "const hashlib\nimport hashlib", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "json", - "content": "const json\nimport json", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Path", - "content": "const Path\nPath = pathlib.Path", - "start_line": 5, - "end_line": 5, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "Any", - "content": "const Any\nAny = typing.Any", - "start_line": 6, - "end_line": 6, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/config/file_loader.py", - "title": "annotations", - "content": "const annotations\nannotations = __future__.annotations", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:instantiates", - "content": "create_runtime instantiates RuntimeManager", - "start_line": 17, - "end_line": 17, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.register_module", - "start_line": 28, - "end_line": 28, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:calls", - "content": "create_runtime calls runtime.control_plane.register_channel", - "start_line": 21, - "end_line": 27, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/plba/bootstrap.py", - "title": "create_runtime:reads_attr", - "content": "create_runtime reads_attr runtime.add_config_file", - "start_line": 19, - "end_line": 19, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/bootstrap.py", - "title": "src/plba/bootstrap.py:create_runtime", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "start_line": 8, - "end_line": 29, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as PublicWorkerHealth\n from plba import WorkerStatus as PublicWorkerStatus\n from plba import create_runtime\n\n config_path = tmp_path / \"config.yml\"\n config_path.write_text(\"platform: {}\\n\", encoding=\"utf-8\")\n\n queue = InMemoryTaskQueue[int]()\n queue.put(2)\n assert queue.get(timeout=0.01) == 2\n queue.task_done()\n\n class PublicRoutine:\n def __init__(self) -> None:\n self.runs = 0\n\n def run(self) -> None:\n if self.runs == 0:\n self.runs += 1\n\n class PublicWorkerImpl(PublicWorker):\n def __init__(self, routine: PublicRoutine) -> None:\n self._inner = RoutineWorker(\"public-worker\", routine)\n\n @property\n def name(self) -> str:\n return self._inner.name\n\n @property\n def critical(self) -> bool:\n return self._inner.critical\n\n def start(self) -> None:\n self._inner.start()\n\n def stop(self, force: bool = False) -> None:\n self._inner.stop(force=force)\n\n def health(self) -> PublicWorkerHealth:\n return self._inner.health()\n\n def status(self) -> PublicWorkerStatus:\n return self._inner.status()\n\n class PublicExampleModule(PublicApplicationModule):\n @property\n def name(self) -> str:\n return \"public-example\"\n\n def register(self, registry: ModuleRegistry) -> None:\n registry.add_worker(PublicWorkerImpl(PublicRoutine()))\n\n runtime = create_runtime(PublicExampleModule(), config_path=str(config_path))\n runtime.start()\n sleep(0.2)\n assert runtime.configuration.get() == {\"platform\": {}}\n assert runtime.status()[\"workers\"][\"registered\"] == 1\n assert hasattr(plba, \"QueueWorker\") is False\n runtime.stop()", - "start_line": 342, - "end_line": 405, - "metadata": { - "chunk_index": 13, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/__init__.py", - "title": "src/app_runtime/config/__init__.py:1-4", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/file_loader.py", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "start_line": 11, - "end_line": 48, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/config.py", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/health.py", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/application.py", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "start_line": 8, - "end_line": 16, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.add_config_file" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime instantiates RuntimeManager" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.register_module" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime calls runtime.control_plane.register_channel" - }, - { - "path": "src/plba/bootstrap.py", - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "create_runtime reads_attr runtime.add_config_file" - } - ], - "entrypoints": [], - "test_candidates": [ - { - "path": "tests/test_runtime.py", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as Public" - } - ], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "const FileConfigProvider\nFileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "layer": "C1_SYMBOL_CATALOG", - "title": "FileConfigProvider", - "span_start": 2, - "span_end": 2, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e449b19e5881889adeb6e056eafe1da30acbae864f06984ea2edc7c15f7cb6d6", - "qname": "FileConfigProvider", - "kind": "const", - "signature": "FileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as PublicWorkerHealth\n from plba import WorkerStatus as PublicWorkerStatus\n from plba import create_runtime\n\n config_path = tmp_path / \"config.yml\"\n config_path.write_text(\"platform: {}\\n\", encoding=\"utf-8\")\n\n queue = InMemoryTaskQueue[int]()\n queue.put(2)\n assert queue.get(timeout=0.01) == 2\n queue.task_done()\n\n class PublicRoutine:\n def __init__(self) -> None:\n self.runs = 0\n\n def run(self) -> None:\n if self.runs == 0:\n self.runs += 1\n\n class PublicWorkerImpl(PublicWorker):\n def __init__(self, routine: PublicRoutine) -> None:\n self._inner = RoutineWorker(\"public-worker\", routine)\n\n @property\n def name(self) -> str:\n return self._inner.name\n\n @property\n def critical(self) -> bool:\n return self._inner.critical\n\n def start(self) -> None:\n self._inner.start()\n\n def stop(self, force: bool = False) -> None:\n self._inner.stop(force=force)\n\n def health(self) -> PublicWorkerHealth:\n return self._inner.health()\n\n def status(self) -> PublicWorkerStatus:\n return self._inner.status()\n\n class PublicExampleModule(PublicApplicationModule):\n @property\n def name(self) -> str:\n return \"public-example\"\n\n def register(self, registry: ModuleRegistry) -> None:\n registry.add_worker(PublicWorkerImpl(PublicRoutine()))\n\n runtime = create_runtime(PublicExampleModule(), config_path=str(config_path))\n runtime.start()\n sleep(0.2)\n assert runtime.configuration.get() == {\"platform\": {}}\n assert runtime.status()[\"workers\"][\"registered\"] == 1\n assert hasattr(plba, \"QueueWorker\") is False\n runtime.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "span_start": 342, - "span_end": 405, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 13, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 26, - "C2_DEPENDENCY_GRAPH": 29, - "C0_SOURCE_CHUNKS": 12 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const create_runtime\ncreate_runtime = plba.bootstrap.create_runtime", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 1, - "span_end": 1, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "fa1e84f16c8c659bcd5448637386af4d15d431064e07714e34689ee64233cb51", - "qname": "create_runtime", - "kind": "const", - "signature": "create_runtime = plba.bootstrap.create_runtime", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "function create_runtime\ncreate_runtime(module)", - "layer": "C1_SYMBOL_CATALOG", - "title": "create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "qname": "create_runtime", - "kind": "function", - "signature": "create_runtime(module)", - "parent_symbol_id": null, - "package_or_module": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "const FileConfigProvider\nFileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "layer": "C1_SYMBOL_CATALOG", - "title": "FileConfigProvider", - "span_start": 2, - "span_end": 2, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e449b19e5881889adeb6e056eafe1da30acbae864f06984ea2edc7c15f7cb6d6", - "qname": "FileConfigProvider", - "kind": "const", - "signature": "FileConfigProvider = app_runtime.config.providers.FileConfigProvider", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const hashlib\nimport hashlib", - "layer": "C1_SYMBOL_CATALOG", - "title": "hashlib", - "span_start": 3, - "span_end": 3, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e7375824bd473da3d73d316d22e3cb6428930e2db1ffbd900ce5a8b88427bf05", - "qname": "hashlib", - "kind": "const", - "signature": "import hashlib", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const json\nimport json", - "layer": "C1_SYMBOL_CATALOG", - "title": "json", - "span_start": 4, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "bb9e2eaf992bfd050f7072d72eed87c55b1a4b001daa034a0f7c630a61bb1d78", - "qname": "json", - "kind": "const", - "signature": "import json", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Path\nPath = pathlib.Path", - "layer": "C1_SYMBOL_CATALOG", - "title": "Path", - "span_start": 5, - "span_end": 5, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "b785967ed1fb83aa62d5724c6d6e9c6d2b1505523db39bd941cc39b48db48306", - "qname": "Path", - "kind": "const", - "signature": "Path = pathlib.Path", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const Any\nAny = typing.Any", - "layer": "C1_SYMBOL_CATALOG", - "title": "Any", - "span_start": 6, - "span_end": 6, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "8e330833b8073585db1c4b4315947c400683a23e4c3d2e2ccbcb260f347541b6", - "qname": "Any", - "kind": "const", - "signature": "Any = typing.Any", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "5ed640ccec43a78659d50ec24f3717bf1144a182c22588f37456649ac6a4a815", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime instantiates RuntimeManager", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:instantiates", - "span_start": 17, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", - "edge_type": "instantiates", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": "27158ca220022eeb5083c6addf8a50775d45f7161284fd60aac48410105f4b98", - "dst_ref": "RuntimeManager", - "resolution": "resolved", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.register_module", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 28, - "span_end": 28, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.register_module", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime calls runtime.control_plane.register_channel", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:calls", - "span_start": 21, - "span_end": 27, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", - "edge_type": "calls", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.control_plane.register_channel", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "create_runtime reads_attr runtime.add_config_file", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "create_runtime:reads_attr", - "span_start": 19, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", - "edge_type": "reads_attr", - "src_symbol_id": "bf07296d9990db302024370ae28446c5a392411cc7188f4607c37a888f125dc3", - "src_qname": "create_runtime", - "dst_symbol_id": null, - "dst_ref": "runtime.add_config_file", - "resolution": "partial", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/bootstrap.py", - "content": "def create_runtime(\n module: ApplicationModule,\n *,\n config_path: str | None = None,\n enable_http_control: bool = False,\n control_host: str = \"127.0.0.1\",\n control_port: int = 8080,\n control_timeout: int = 5,\n) -> RuntimeManager:\n runtime = RuntimeManager()\n if config_path is not None:\n runtime.add_config_file(config_path)\n if enable_http_control:\n runtime.control_plane.register_channel(\n HttpControlChannel(\n host=control_host,\n port=control_port,\n timeout=control_timeout,\n )\n )\n runtime.register_module(module)\n return runtime", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/bootstrap.py:create_runtime", - "span_start": 8, - "span_end": 29, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.plba.bootstrap", - "is_test": false, - "blob_sha": "ce2dc59c27bacd29e0d219729b307c6851ab3aab1a115c2e0054a869affdcbbd", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "tests/test_runtime.py", - "content": "def test_public_plba_package_exports_runtime_builder_and_worker_contract(tmp_path) -> None:\n import plba\n from plba import ApplicationModule as PublicApplicationModule\n from plba import InMemoryTaskQueue\n from plba import Worker as PublicWorker\n from plba import WorkerHealth as PublicWorkerHealth\n from plba import WorkerStatus as PublicWorkerStatus\n from plba import create_runtime\n\n config_path = tmp_path / \"config.yml\"\n config_path.write_text(\"platform: {}\\n\", encoding=\"utf-8\")\n\n queue = InMemoryTaskQueue[int]()\n queue.put(2)\n assert queue.get(timeout=0.01) == 2\n queue.task_done()\n\n class PublicRoutine:\n def __init__(self) -> None:\n self.runs = 0\n\n def run(self) -> None:\n if self.runs == 0:\n self.runs += 1\n\n class PublicWorkerImpl(PublicWorker):\n def __init__(self, routine: PublicRoutine) -> None:\n self._inner = RoutineWorker(\"public-worker\", routine)\n\n @property\n def name(self) -> str:\n return self._inner.name\n\n @property\n def critical(self) -> bool:\n return self._inner.critical\n\n def start(self) -> None:\n self._inner.start()\n\n def stop(self, force: bool = False) -> None:\n self._inner.stop(force=force)\n\n def health(self) -> PublicWorkerHealth:\n return self._inner.health()\n\n def status(self) -> PublicWorkerStatus:\n return self._inner.status()\n\n class PublicExampleModule(PublicApplicationModule):\n @property\n def name(self) -> str:\n return \"public-example\"\n\n def register(self, registry: ModuleRegistry) -> None:\n registry.add_worker(PublicWorkerImpl(PublicRoutine()))\n\n runtime = create_runtime(PublicExampleModule(), config_path=str(config_path))\n runtime.start()\n sleep(0.2)\n assert runtime.configuration.get() == {\"platform\": {}}\n assert runtime.status()[\"workers\"][\"registered\"] == 1\n assert hasattr(plba, \"QueueWorker\") is False\n runtime.stop()", - "layer": "C0_SOURCE_CHUNKS", - "title": "tests/test_runtime.py:test_public_plba_package_exports_runtime_builder_and_worker_contract", - "span_start": 342, - "span_end": 405, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 13, - "chunk_type": "symbol_block", - "module_or_unit": "tests.test_runtime", - "is_test": true, - "blob_sha": "336335976a7892e997ef1549c1e59db9d44b8eb61c914ef98e2869941306407b", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": true, - "action": "return", - "reasons": [] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md deleted file mode 100644 index 2a2e869..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Прямых тестов для `create_runtime` не обнаружено. Ближайший тест находится в файле `tests/test_runtime.py`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод `create_runtime`. Косвенное покрытие отсутствует.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md deleted file mode 100644 index e237500..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-runtime-manager - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для RuntimeManager? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Прямые тесты для `RuntimeManager` обнаружены в следующих файлах:\n\n- **tests/test_runtime.py**: проверка инициализации и поведения `RuntimeManager`.\n- **tests/test_business_control_actions.py**: хотя этот файл упоминает `RuntimeManager`, он непосредственно не предназначен для тестирования `RuntimeManager`. Вместо этого здесь проверяются контрольные каналы и бизнес-действия.\n\nКосвенных тестов, специфичных для `RuntimeManager`, не найдено.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md deleted file mode 100644 index cd1b133..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для TraceService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Прямые тесты для `TraceService` находятся в файле `tests/test_runtime.py`.\n\nВ следующих функциях проверяются различные аспекты работы `TraceService`:\n- `test_trace_service_allows_messages_without_status`: проверяет корректность записи сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверяет поддержку различных уровней логирования.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json deleted file mode 100644 index a062465..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json +++ /dev/null @@ -1,3001 +0,0 @@ -{ - "case_id": "plba-v2-find-tests-workflow-runtime-factory-negative", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", - "runner": "agent_runtime", - "mode": "full_chain", - "query": "Где тесты для WorkflowRuntimeFactory?", - "actual": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Insufficient evidence for a confident answer. No test candidates found.", - "answer_mode": "degraded", - "path_scope": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "passed": true, - "mismatches": [], - "details": { - "query": "Где тесты для WorkflowRuntimeFactory?", - "router_result": { - "schema_version": "1.1", - "intent": "CODE_QA", - "retrieval_profile": "code", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "query_plan": { - "raw": "Где тесты для WorkflowRuntimeFactory?", - "normalized": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "WorkflowRuntimeFactory" - ], - "keyword_hints": [ - "WorkflowRuntimeFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "WorkflowRuntimeFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 36 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - }, - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_workflow_runtime_factory", - "TestWorkflowRuntimeFactory", - "WorkflowRuntimeFactory" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, - "alternatives": [ - "WorkflowRuntimeFactory" - ], - "confidence": 0.0 - }, - "evidence_policy": { - "require_def": true, - "require_flow": true, - "require_spec": false, - "allow_answer_without_evidence": false - } - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "keyword_hints": [ - "WorkflowRuntimeFactory" - ], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_spec": { - "domains": [ - "CODE" - ], - "layer_queries": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "top_k": 8 - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "top_k": 6 - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "top_k": 10 - } - ], - "filters": { - "test_policy": "INCLUDE", - "path_scope": [], - "language": [ - "python" - ] - }, - "rerank_profile": "code" - }, - "retrieval_constraints": { - "include_globs": [ - "src/**", - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "exclude_globs": [], - "prefer_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py" - ], - "test_file_globs": [ - "tests/**", - "**/test_*.py", - "**/*_test.py", - "**/conftest.py" - ], - "test_symbol_patterns": [ - "test_workflow_runtime_factory", - "TestWorkflowRuntimeFactory", - "WorkflowRuntimeFactory" - ], - "max_candidates": 20, - "fuzzy_symbol_search": { - "enabled": true, - "max_distance": 2, - "top_k": 5 - } - }, - "query_plan": { - "raw": "Где тесты для WorkflowRuntimeFactory?", - "normalized": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "negations": [], - "expansions": [ - "test", - "unit test", - "WorkflowRuntimeFactory" - ], - "keyword_hints": [ - "WorkflowRuntimeFactory" - ], - "path_hints": [], - "doc_scope_hints": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "symbol_kind_hint": "class", - "anchors": [ - { - "type": "SYMBOL", - "value": "WorkflowRuntimeFactory", - "source": "user_text", - "subtype": null, - "span": { - "start": 14, - "end": 36 - }, - "confidence": 0.88 - }, - { - "type": "KEY_TERM", - "value": "тест", - "source": "user_text", - "subtype": null, - "span": { - "start": 4, - "end": 9 - }, - "confidence": 0.9 - } - ] - } - }, - "retrieval_result": { - "target_symbol_candidates": [ - "WorkflowRuntimeFactory", - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory.create_engine", - "WorkflowPersistence", - "annotations", - "WorkflowEngine" - ], - "resolved_symbol": "WorkflowRuntimeFactory", - "symbol_resolution_status": "resolved", - "file_candidates": [ - "src/plba/__init__.py", - "src/app_runtime/workflow/runtime_factory.py", - "src/plba/workflow.py", - "src/app_runtime/config/__init__.py", - "src/app_runtime/config/providers.py", - "src/app_runtime/contracts/__init__.py", - "src/app_runtime/config/file_loader.py", - "src/app_runtime/contracts/config.py", - "src/app_runtime/contracts/health.py", - "src/app_runtime/contracts/application.py" - ], - "code_chunks": [ - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/__init__.py", - "title": "WorkflowRuntimeFactory", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "start_line": 21, - "end_line": 30, - "metadata": { - "symbol_id": "cb7c73db05c2622aac89114bed1cddd1d567de21cfac5c53037c62b1074b25c9", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory", - "content": "class WorkflowRuntimeFactory\nWorkflowRuntimeFactory", - "start_line": 7, - "end_line": 19, - "metadata": { - "symbol_id": "9da827270329de64ebb426fadaaa5e35145e6666b92c6da186e08bf4b071f458", - "qname": "WorkflowRuntimeFactory", - "kind": "class", - "signature": "WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/plba/workflow.py", - "title": "WorkflowRuntimeFactory", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "start_line": 7, - "end_line": 7, - "metadata": { - "symbol_id": "80865947d1ca709971efe9d68a9ee1f348c1c43d351bf4e1b4a5884d72985b6b", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__", - "content": "method WorkflowRuntimeFactory.__init__\n__init__(self, connection_factory)", - "start_line": 8, - "end_line": 12, - "metadata": { - "symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "qname": "WorkflowRuntimeFactory.__init__", - "kind": "method", - "signature": "__init__(self, connection_factory)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.create_engine", - "content": "method WorkflowRuntimeFactory.create_engine\ncreate_engine(self, workflow)", - "start_line": 14, - "end_line": 19, - "metadata": { - "symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "qname": "WorkflowRuntimeFactory.create_engine", - "kind": "method", - "signature": "create_engine(self, workflow)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowPersistence", - "content": "const WorkflowPersistence\nWorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "start_line": 4, - "end_line": 4, - "metadata": { - "symbol_id": "35693d37698e35079400b6a021d46209966ce469d9f77763d1c82d82ef4600b2", - "qname": "WorkflowPersistence", - "kind": "const", - "signature": "WorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "annotations", - "content": "const annotations\nannotations = __future__.annotations", - "start_line": 1, - "end_line": 1, - "metadata": { - "symbol_id": "e016ec68f9d15d52fe0505774229fafc705c1bf3dfda78845a3db9b032a4441d", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C1_SYMBOL_CATALOG", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowEngine", - "content": "const WorkflowEngine\nWorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "start_line": 3, - "end_line": 3, - "metadata": { - "symbol_id": "da4aee8bc7d248177fbc4f892732c6eb08baa6d268c32921a217747143a99fe0", - "qname": "WorkflowEngine", - "kind": "const", - "signature": "WorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 11, - "end_line": 19, - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 12, - "end_line": 17, - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 9, - "end_line": 16, - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine", - "start_line": 10, - "end_line": 19, - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.__init__:writes_attr", - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer", - "start_line": 12, - "end_line": 12, - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C2_DEPENDENCY_GRAPH", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "WorkflowRuntimeFactory.create_engine:calls", - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default", - "start_line": 15, - "end_line": 18, - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/workflow/runtime_factory.py", - "title": "src/app_runtime/workflow/runtime_factory.py:WorkflowRuntimeFactory", - "content": "class WorkflowRuntimeFactory:\n def __init__(self, connection_factory=None, *, traces, hooks=None, snapshot_sanitizer=None) -> None:\n self._connection_factory = connection_factory\n self._traces = traces\n self._hooks = hooks\n self._snapshot_sanitizer = snapshot_sanitizer\n\n def create_engine(self, workflow) -> WorkflowEngine:\n persistence = WorkflowPersistence.create_default(\n self._connection_factory,\n snapshot_sanitizer=self._snapshot_sanitizer,\n )\n return WorkflowEngine(workflow, persistence, traces=self._traces, hooks=self._hooks)", - "start_line": 7, - "end_line": 19, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/__init__.py", - "title": "src/plba/__init__.py:1-69", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "start_line": 1, - "end_line": 69, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/plba/workflow.py", - "title": "src/plba/workflow.py:1-18", - "content": "from app_runtime.workflow.contracts.context import WorkflowContext\nfrom app_runtime.workflow.contracts.result import StepResult\nfrom app_runtime.workflow.contracts.step import WorkflowStep\nfrom app_runtime.workflow.contracts.workflow import WorkflowDefinition, WorkflowNode\nfrom app_runtime.workflow.engine.hooks import WorkflowEngineHooks\nfrom app_runtime.workflow.engine.workflow_engine import WorkflowEngine\nfrom app_runtime.workflow.runtime_factory import WorkflowRuntimeFactory\n\n__all__ = [\n \"StepResult\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n]", - "start_line": 1, - "end_line": 18, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/__init__.py", - "title": "src/app_runtime/config/__init__.py:1-4", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "start_line": 1, - "end_line": 4, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/providers.py", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "start_line": 10, - "end_line": 22, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/__init__.py", - "title": "src/app_runtime/__init__.py:1-1", - "content": "__all__: list[str] = []", - "start_line": 1, - "end_line": 1, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/config/file_loader.py", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "start_line": 11, - "end_line": 48, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/config.py", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/health.py", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "start_line": 7, - "end_line": 10, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "layer": "C0_SOURCE_CHUNKS", - "path": "src/app_runtime/contracts/application.py", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "start_line": 8, - "end_line": 16, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "relations": [ - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer" - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - }, - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default" - } - ], - "entrypoints": [], - "test_candidates": [], - "layer_outcomes": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "missing_layers": [], - "raw_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 21, - "span_end": 30, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "cb7c73db05c2622aac89114bed1cddd1d567de21cfac5c53037c62b1074b25c9", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory\nWorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "9da827270329de64ebb426fadaaa5e35145e6666b92c6da186e08bf4b071f458", - "qname": "WorkflowRuntimeFactory", - "kind": "class", - "signature": "WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "80865947d1ca709971efe9d68a9ee1f348c1c43d351bf4e1b4a5884d72985b6b", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.__init__\n__init__(self, connection_factory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.__init__", - "span_start": 8, - "span_end": 12, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "qname": "WorkflowRuntimeFactory.__init__", - "kind": "method", - "signature": "__init__(self, connection_factory)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.create_engine\ncreate_engine(self, workflow)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.create_engine", - "span_start": 14, - "span_end": 19, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "qname": "WorkflowRuntimeFactory.create_engine", - "kind": "method", - "signature": "create_engine(self, workflow)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowPersistence\nWorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowPersistence", - "span_start": 4, - "span_end": 4, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "35693d37698e35079400b6a021d46209966ce469d9f77763d1c82d82ef4600b2", - "qname": "WorkflowPersistence", - "kind": "const", - "signature": "WorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "e016ec68f9d15d52fe0505774229fafc705c1bf3dfda78845a3db9b032a4441d", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowEngine\nWorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowEngine", - "span_start": 3, - "span_end": 3, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": null, - "metadata": { - "symbol_id": "da4aee8bc7d248177fbc4f892732c6eb08baa6d268c32921a217747143a99fe0", - "qname": "WorkflowEngine", - "kind": "const", - "signature": "WorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 11, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 12, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 9, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 10, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:writes_attr", - "span_start": 12, - "span_end": 12, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.create_engine:calls", - "span_start": 15, - "span_end": 18, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": null, - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory:\n def __init__(self, connection_factory=None, *, traces, hooks=None, snapshot_sanitizer=None) -> None:\n self._connection_factory = connection_factory\n self._traces = traces\n self._hooks = hooks\n self._snapshot_sanitizer = snapshot_sanitizer\n\n def create_engine(self, workflow) -> WorkflowEngine:\n persistence = WorkflowPersistence.create_default(\n self._connection_factory,\n snapshot_sanitizer=self._snapshot_sanitizer,\n )\n return WorkflowEngine(workflow, persistence, traces=self._traces, hooks=self._hooks)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/workflow/runtime_factory.py:WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "from app_runtime.workflow.contracts.context import WorkflowContext\nfrom app_runtime.workflow.contracts.result import StepResult\nfrom app_runtime.workflow.contracts.step import WorkflowStep\nfrom app_runtime.workflow.contracts.workflow import WorkflowDefinition, WorkflowNode\nfrom app_runtime.workflow.engine.hooks import WorkflowEngineHooks\nfrom app_runtime.workflow.engine.workflow_engine import WorkflowEngine\nfrom app_runtime.workflow.runtime_factory import WorkflowRuntimeFactory\n\n__all__ = [\n \"StepResult\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/workflow.py:1-18", - "span_start": 1, - "span_end": 18, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": null, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "retrieval_report": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 34, - "C2_DEPENDENCY_GRAPH": 38, - "C0_SOURCE_CHUNKS": 33 - } - } - }, - "diagnostics": { - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": false, - "answer_mode": "degraded", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "pending" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для WorkflowRuntimeFactory?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": false, - "failure_reasons": [ - "tests_not_found" - ], - "evidence_count": 24 - }, - "failure_reasons": [ - "tests_not_found" - ], - "timings_ms": {} - }, - "rag_rows": [ - { - "path": "src/plba/__init__.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 21, - "span_end": 30, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "cb7c73db05c2622aac89114bed1cddd1d567de21cfac5c53037c62b1074b25c9", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = plba.workflow.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory\nWorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "9da827270329de64ebb426fadaaa5e35145e6666b92c6da186e08bf4b071f458", - "qname": "WorkflowRuntimeFactory", - "kind": "class", - "signature": "WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "const WorkflowRuntimeFactory\nWorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 7, - "lexical_rank": 0, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "80865947d1ca709971efe9d68a9ee1f348c1c43d351bf4e1b4a5884d72985b6b", - "qname": "WorkflowRuntimeFactory", - "kind": "const", - "signature": "WorkflowRuntimeFactory = app_runtime.workflow.runtime_factory.WorkflowRuntimeFactory", - "parent_symbol_id": null, - "package_or_module": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.__init__\n__init__(self, connection_factory)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.__init__", - "span_start": 8, - "span_end": 12, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "qname": "WorkflowRuntimeFactory.__init__", - "kind": "method", - "signature": "__init__(self, connection_factory)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "method WorkflowRuntimeFactory.create_engine\ncreate_engine(self, workflow)", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowRuntimeFactory.create_engine", - "span_start": 14, - "span_end": 19, - "lexical_rank": 3, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "qname": "WorkflowRuntimeFactory.create_engine", - "kind": "method", - "signature": "create_engine(self, workflow)", - "parent_symbol_id": "WorkflowRuntimeFactory", - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowPersistence\nWorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowPersistence", - "span_start": 4, - "span_end": 4, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "35693d37698e35079400b6a021d46209966ce469d9f77763d1c82d82ef4600b2", - "qname": "WorkflowPersistence", - "kind": "const", - "signature": "WorkflowPersistence = app_runtime.workflow.persistence.WorkflowPersistence", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const annotations\nannotations = __future__.annotations", - "layer": "C1_SYMBOL_CATALOG", - "title": "annotations", - "span_start": 1, - "span_end": 1, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "e016ec68f9d15d52fe0505774229fafc705c1bf3dfda78845a3db9b032a4441d", - "qname": "annotations", - "kind": "const", - "signature": "annotations = __future__.annotations", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "const WorkflowEngine\nWorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "layer": "C1_SYMBOL_CATALOG", - "title": "WorkflowEngine", - "span_start": 3, - "span_end": 3, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 1, - "distance": NaN, - "metadata": { - "symbol_id": "da4aee8bc7d248177fbc4f892732c6eb08baa6d268c32921a217747143a99fe0", - "qname": "WorkflowEngine", - "kind": "const", - "signature": "WorkflowEngine = app_runtime.workflow.engine.workflow_engine.WorkflowEngine", - "parent_symbol_id": null, - "package_or_module": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._hooks\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 11, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._hooks", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._snapshot_sanitizer\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 12, - "span_end": 17, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._snapshot_sanitizer", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._connection_factory\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 9, - "span_end": 16, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._connection_factory", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__\n -> WorkflowRuntimeFactory._traces\n -> WorkflowRuntimeFactory.create_engine", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:dataflow_slice", - "span_start": 10, - "span_end": 19, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 3, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "edge_type": "dataflow_slice", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "dst_ref": "WorkflowRuntimeFactory.create_engine", - "resolution": "resolved", - "slice_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", - "root_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "path_symbols": [ - "WorkflowRuntimeFactory.__init__", - "WorkflowRuntimeFactory._traces", - "WorkflowRuntimeFactory.create_engine" - ], - "path_symbol_ids": [ - "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333" - ], - "path_edge_types": [ - "writes_attr", - "reads_attr" - ], - "path_length": 3, - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.__init__ writes_attr WorkflowRuntimeFactory._snapshot_sanitizer", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.__init__:writes_attr", - "span_start": 12, - "span_end": 12, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", - "edge_type": "writes_attr", - "src_symbol_id": "d82a367758b2f7bcce3d351e576f25768b0afe8b915d01ace1c7d6380f14f52f", - "src_qname": "WorkflowRuntimeFactory.__init__", - "dst_symbol_id": null, - "dst_ref": "WorkflowRuntimeFactory._snapshot_sanitizer", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default", - "layer": "C2_DEPENDENCY_GRAPH", - "title": "WorkflowRuntimeFactory.create_engine:calls", - "span_start": 15, - "span_end": 18, - "lexical_rank": 4, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 3, - "distance": NaN, - "metadata": { - "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", - "edge_type": "calls", - "src_symbol_id": "86f3a0bf3332952bf469e564748f16f1f7814ab51d5a963e5eb33de5e171b333", - "src_qname": "WorkflowRuntimeFactory.create_engine", - "dst_symbol_id": null, - "dst_ref": "WorkflowPersistence.create_default", - "resolution": "partial", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/workflow/runtime_factory.py", - "content": "class WorkflowRuntimeFactory:\n def __init__(self, connection_factory=None, *, traces, hooks=None, snapshot_sanitizer=None) -> None:\n self._connection_factory = connection_factory\n self._traces = traces\n self._hooks = hooks\n self._snapshot_sanitizer = snapshot_sanitizer\n\n def create_engine(self, workflow) -> WorkflowEngine:\n persistence = WorkflowPersistence.create_default(\n self._connection_factory,\n snapshot_sanitizer=self._snapshot_sanitizer,\n )\n return WorkflowEngine(workflow, persistence, traces=self._traces, hooks=self._hooks)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/workflow/runtime_factory.py:WorkflowRuntimeFactory", - "span_start": 7, - "span_end": 19, - "lexical_rank": 5, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.workflow.runtime_factory", - "is_test": false, - "blob_sha": "4d03c095f3082eb3ea8d558d65a785eb747fffd9c1383946e6c433bcedb7259a", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/__init__.py", - "content": "from plba.bootstrap import create_runtime\nfrom plba.config import ConfigFileLoader, FileConfigProvider\nfrom plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\nfrom plba.contracts import (\n ApplicationModule,\n ConfigProvider,\n HealthContributor,\n TraceContext,\n TraceContextRecord,\n TraceLogMessage,\n TraceTransport,\n Worker,\n WorkerHealth,\n WorkerStatus,\n)\nfrom plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\nfrom plba.health import HealthRegistry\nfrom plba.logging import LogManager\nfrom plba.queue import InMemoryTaskQueue\nfrom plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\nfrom plba.workflow import (\n StepResult,\n WorkflowContext,\n WorkflowDefinition,\n WorkflowEngine,\n WorkflowEngineHooks,\n WorkflowNode,\n WorkflowRuntimeFactory,\n WorkflowStep,\n)\nfrom plba.workers import WorkerSupervisor\n\n__all__ = [\n \"ApplicationModule\",\n \"ConfigFileLoader\",\n \"ConfigProvider\",\n \"ConfigurationManager\",\n \"ControlActionSet\",\n \"ControlChannel\",\n \"ControlPlaneService\",\n \"create_runtime\",\n \"FileConfigProvider\",\n \"HealthContributor\",\n \"HealthRegistry\",\n \"HttpControlChannel\",\n \"InMemoryTaskQueue\",\n \"LogManager\",\n \"MySqlTraceTransport\",\n \"NoOpTraceTransport\",\n \"RuntimeManager\",\n \"ServiceContainer\",\n \"TraceContext\",\n \"TraceContextRecord\",\n \"TraceLogMessage\",\n \"TraceService\",\n \"TraceTransport\",\n \"StepResult\",\n \"Worker\",\n \"WorkerHealth\",\n \"WorkerStatus\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n \"WorkerSupervisor\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/__init__.py:1-69", - "span_start": 1, - "span_end": 69, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.__init__", - "is_test": false, - "blob_sha": "24e755ec8c249d14fb0e675b5dbf2b71ab91afb9c849897eebfa9feb2499e19d", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/plba/workflow.py", - "content": "from app_runtime.workflow.contracts.context import WorkflowContext\nfrom app_runtime.workflow.contracts.result import StepResult\nfrom app_runtime.workflow.contracts.step import WorkflowStep\nfrom app_runtime.workflow.contracts.workflow import WorkflowDefinition, WorkflowNode\nfrom app_runtime.workflow.engine.hooks import WorkflowEngineHooks\nfrom app_runtime.workflow.engine.workflow_engine import WorkflowEngine\nfrom app_runtime.workflow.runtime_factory import WorkflowRuntimeFactory\n\n__all__ = [\n \"StepResult\",\n \"WorkflowContext\",\n \"WorkflowDefinition\",\n \"WorkflowEngine\",\n \"WorkflowEngineHooks\",\n \"WorkflowNode\",\n \"WorkflowRuntimeFactory\",\n \"WorkflowStep\",\n]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/plba/workflow.py:1-18", - "span_start": 1, - "span_end": 18, - "lexical_rank": 6, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.plba.workflow", - "is_test": false, - "blob_sha": "f227797606042273d1f1798f76846952892eeb9e4e9e6a38fb8a631d7231ff39", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/__init__.py", - "content": "from app_runtime.config.file_loader import ConfigFileLoader\nfrom app_runtime.config.providers import FileConfigProvider\n\n__all__ = [\"ConfigFileLoader\", \"FileConfigProvider\"]", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/__init__.py:1-4", - "span_start": 1, - "span_end": 4, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.config.__init__", - "is_test": false, - "blob_sha": "612918029820a2a983330ec92256142b55b9de4bdf3399ece18e2a02dbad9729", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/providers.py", - "content": "class FileConfigProvider(ConfigProvider):\n def __init__(self, path: str | Path) -> None:\n self._loader = ConfigFileLoader(path)\n\n @property\n def loader(self) -> ConfigFileLoader:\n return self._loader\n\n def load(self) -> dict[str, Any]:\n config = self._loader.load_sync()\n if not isinstance(config, dict):\n raise TypeError(\"Config root must be a mapping\")\n return dict(config)", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/providers.py:FileConfigProvider", - "span_start": 10, - "span_end": 22, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.providers", - "is_test": false, - "blob_sha": "8c53ca0122d6df6c5763bca15e99434bb4daebd5a618b8fc927e9ae90b022e64", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/__init__.py", - "content": "__all__: list[str] = []", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/__init__.py:1-1", - "span_start": 1, - "span_end": 1, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "window", - "module_or_unit": "src.app_runtime.__init__", - "is_test": false, - "blob_sha": "8eea9df4f6d7b38ca0e39ccc27b04700e3d08dbeec8046d613d22706d19985fa", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/config/file_loader.py", - "content": "class ConfigFileLoader:\n def __init__(self, path: str | Path) -> None:\n self.path = Path(path)\n self.config: Any = None\n self.last_valid_config: Any = None\n self._last_seen_hash: str | None = None\n\n def read_text(self) -> str:\n return self.path.read_text(encoding=\"utf-8\")\n\n def parse(self, data: str) -> Any:\n suffix = self.path.suffix.lower()\n if suffix in {\".yml\", \".yaml\"}:\n return yaml.safe_load(data)\n return json.loads(data)\n\n def load_sync(self) -> Any:\n data = self.read_text()\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = self._calculate_hash(data)\n return parsed\n\n def load_if_changed(self) -> tuple[bool, Any]:\n data = self.read_text()\n current_hash = self._calculate_hash(data)\n if current_hash == self._last_seen_hash:\n return False, self.config\n parsed = self.parse(data)\n self.config = parsed\n self.last_valid_config = parsed\n self._last_seen_hash = current_hash\n return True, parsed\n\n @staticmethod\n def _calculate_hash(data: str) -> str:\n return hashlib.sha256(data.encode(\"utf-8\")).hexdigest()", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/config/file_loader.py:ConfigFileLoader", - "span_start": 11, - "span_end": 48, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.config.file_loader", - "is_test": false, - "blob_sha": "1f19ffebde5e38e4be5a5d5a678059a0f36dedb8fb8b3e00ab395c67106a87ea", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/config.py", - "content": "class ConfigProvider(ABC):\n @abstractmethod\n def load(self) -> dict[str, Any]:\n \"\"\"Return a config fragment.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/config.py:ConfigProvider", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.config", - "is_test": false, - "blob_sha": "5e773880267743ee94954ea2db120c2d88c54d4312893293d1b89df405283ed4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/health.py", - "content": "class HealthContributor(ABC):\n @abstractmethod\n def health(self) -> WorkerHealth:\n \"\"\"Return contributor health state.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/health.py:HealthContributor", - "span_start": 7, - "span_end": 10, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.health", - "is_test": false, - "blob_sha": "6bd92611def7131e32d4dd34a8ed85e6cf3c67722ad27797032a632cb30dc097", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, - { - "path": "src/app_runtime/contracts/application.py", - "content": "class ApplicationModule(ABC):\n @property\n @abstractmethod\n def name(self) -> str:\n \"\"\"Module name used for runtime status and diagnostics.\"\"\"\n\n @abstractmethod\n def register(self, registry: ModuleRegistry) -> None:\n \"\"\"Register workers, services, and health contributors.\"\"\"", - "layer": "C0_SOURCE_CHUNKS", - "title": "src/app_runtime/contracts/application.py:ApplicationModule", - "span_start": 8, - "span_end": 16, - "lexical_rank": 100, - "prefer_bonus": 1, - "test_penalty": 0, - "structural_rank": 99, - "layer_rank": 4, - "distance": NaN, - "metadata": { - "chunk_index": 0, - "chunk_type": "symbol_block", - "module_or_unit": "src.app_runtime.contracts.application", - "is_test": false, - "blob_sha": "197c35634dca49c352ce3f230295a485fbffb672ce7bb8c08e752bfdf61e7fa4", - "repo_id": "plba", - "artifact_type": null, - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - } - ], - "validation": { - "passed": false, - "action": "repair", - "reasons": [ - "degraded_answer_missing_guardrail" - ] - } - } -} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md deleted file mode 100644 index 8d465e3..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md +++ /dev/null @@ -1,32 +0,0 @@ -# plba-v2-find-tests-workflow-runtime-factory-negative - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для WorkflowRuntimeFactory? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Insufficient evidence for a confident answer. No test candidates found.", - "answer_mode": "degraded", - "path_scope": [], - "symbol_candidates": [ - "WorkflowRuntimeFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md deleted file mode 100644 index b301f23..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md +++ /dev/null @@ -1,31 +0,0 @@ -# plba-v2-open-file-nonexistent - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Открой файл src/app_runtime/core/missing_runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 0, - "llm_answer": "Файл `src/app_runtime/core/missing_runtime.py` не найден.", - "answer_mode": "not_found", - "path_scope": [ - "src/app_runtime/core/missing_runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- answer_mode: expected degraded, got not_found -- llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md deleted file mode 100644 index 46fe6af..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md +++ /dev/null @@ -1,30 +0,0 @@ -# plba-v2-open-file-public-api - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/plba/__init__.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "В файле src/plba/__init__.py видны следующие импорты и определения:\n\n- from plba.bootstrap import create_runtime\n- from plba.config import ConfigFileLoader, FileConfigProvider\n- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\n- from plba.contracts import ApplicationModule, ConfigProvider, HealthContributor, TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport, Worker, WorkerHealth, WorkerStatus\n- from plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\n- from plba.health import HealthRegistry\n- from plba.logging import LogManager\n- from plba.queue import InMemoryTaskQueue\n- from plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\n- from plba.workflow import StepResult, WorkflowContext, WorkflowDefinition, Workflo", - "answer_mode": "answered", - "path_scope": [ - "src/plba/__init__.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md deleted file mode 100644 index 4bdf579..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md +++ /dev/null @@ -1,30 +0,0 @@ -# plba-v2-open-file-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/app_runtime/core/runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Виден класс `RuntimeManager` с инициализатором и статическими полями. Файл содержит 162 строки кода.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md deleted file mode 100644 index 98f8b3d..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md +++ /dev/null @@ -1,35 +0,0 @@ -# plba-v2-trace-flow-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи как проходит запрос /health в HttpControlAppFactory - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "Поток выполнения запроса `/health` через `HttpControlAppFactory` выглядит следующим образом:\n\n1. Запрос приходит на сервер и обрабатывается фабрикой приложений `HttpControlAppFactory`.\n2. Внутри фабрики создается экземпляр приложения FastAPI с middleware для логирования времени обработки запросов.\n3. Для маршрута `/health` определяется обработчик, который вызывает предоставленный провайдер здоровья (`health_provider`), ожидающий асинхронный результат типа `HealthPayload`.\n4. В результате выполнения провайдера формируется JSON-ответ с кодом статуса 200 при успешном состоянии (\"ok\"), иначе возвращается статус 503.\n\nТаким образом, ключевой точкой является вызов провайдера здоровья внутри фабрики приложений, от которого зависит итоговый результат ответа.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md deleted file mode 100644 index 55e0ffb..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md +++ /dev/null @@ -1,34 +0,0 @@ -# plba-v2-trace-flow-runtime-start - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи поток выполнения при запуске RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "При запуске `RuntimeManager` выполняются следующие основные шаги:\n\n1. Инициализация через `RuntimeManager.__init__` в файле `src/app_runtime/core/runtime.py`.\n2. Вызов метода `start` внутри `RuntimeManager`, который далее вызывает асинхронную функцию `_start_async`.\n3. В `ControlPlaneService.start` создается экземпляр канала управления с помощью метода `register_channel`.\n4. Канал управления инициализируется через метод `start` экземпляра `ControlChannel`, где создается веб-приложение с использованием фабрики `HttpControlAppFactory`.\n5. Веб-приложение запускается с помощью `UvicornThreadRunner.start`, который выполняет запуск сервера через uvicorn.\n\nТаким образом, поток начинается с инициализации менеджера времени выполнения и завершается запуском веб-канала управления.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/summary.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/summary.md deleted file mode 100644 index a2ae98f..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/summary.md +++ /dev/null @@ -1,85 +0,0 @@ -# pipeline_setup_v3 summary - -Passed: 15/18 - -| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | -|------|------|------|-------|-------------------|------------|------| -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-public-api | full_chain | Открой файл src/plba/__init__.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-trace-service | full_chain | Объясни как работает класс TraceService | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-create-runtime | full_chain | Что делает функция create_runtime? | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-trace-service | full_chain | Где тесты для TraceService? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-create-runtime | full_chain | Где тесты для create_runtime? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-workflow-runtime-factory-negative | full_chain | Где тесты для WorkflowRuntimeFactory? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-control-plane | full_chain | Найди точки входа HTTP control plane | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-health-endpoint | full_chain | Покажи как проходит запрос /health в HttpControlAppFactory | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-control-plane | full_chain | Какие компоненты участвуют в ControlPlaneService? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✗ | - -## Failures -- **plba-v2-find-entrypoints-health-endpoint**: llm: expected answer to contain 'GET /health' -- **plba-v2-explain-nonexistent-symbol**: answer_mode: expected degraded, got answered; retrieval: expected empty rag, got 33 rows; llm: expected answer to contain 'не найдена' -- **plba-v2-open-file-nonexistent**: answer_mode: expected degraded, got not_found; llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.' - -## LLM Answers -- **plba-v2-open-file-runtime** - Query: Открой файл src/app_runtime/core/runtime.py - > Виден класс \`RuntimeManager\` с инициализатором и статическими полями. Файл содержит 162 строки кода. -- **plba-v2-open-file-public-api** - Query: Открой файл src/plba/__init__.py - > В файле src/plba/\_\_init\_\_.py видны следующие импорты и определения: \- from plba.bootstrap import create\_runtime \- from plba.config import ConfigFileLoader, FileConfigProvider \- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel \- from plba.contracts import ApplicationModule, ConfigProvider, HealthContributor, TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport, Worker, WorkerHealth, WorkerStatus \- from plba.core import ConfigurationManager, RuntimeManager, ServiceContainer \- from plba.health import HealthRegistry \- from plba.logging import LogManager \- from plba.queue import InMemoryTaskQueue \- from plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService \- from plba.workflow import StepResult, WorkflowContext, WorkflowDefinition, Workflo -- **plba-v2-explain-runtime-manager** - Query: Объясни как работает класс RuntimeManager - > Класс \`RuntimeManager\` определен в файле \`src/app\_runtime/core/runtime.py\`, начиная с строки 18. Из доступных контекстных данных напрямую невозможно точно описать его работу, так как отсутствует подробная реализация или вызовы этого класса. Тем не менее, можно сделать осторожные выводы: \- Класс играет роль менеджера и управляет состоянием выполнения приложения. \- Вероятно, он участвует в координации различных компонентов и служб через атрибуты и методы, такие как чтение и запись состояния \(\`configuration\`, \`add\_config\_file\`\), а также участие в срезах данных потока выполнения \(\`participates in dataflow slices\`\). \- На основании имеющихся свидетельств сложно точно понять, какие конкретно действия выполняет этот класс при инициализации и во время своей работы. -- **plba-v2-explain-trace-service** - Query: Объясни как работает класс TraceService - > Класс \`TraceService\` находится в файле \`src/app\_runtime/tracing/service.py\`. Это сервис для управления контекстами трассировки и записи событий в журнал. Его основные обязанности: \- Инициализация сервиса при создании экземпляра \(\`\_\_init\_\_\`\) с передачей транспортов и хранилищ контекста. \- Создание нового контекста трассировки через метод \`create\_context\`, который генерирует уникальный идентификатор трассировки и сохраняет запись контекста в хранилище. \- Предоставление текущего идентификатора трассировки через метод \`current\_trace\_id\`. Конструктор принимает два необязательных параметра: \- \`transport\`: транспорт для отправки сообщений трассировки \(по умолчанию используется \`NoOpTraceTransport\`\). \- \`store\`: хранилище контекста \(по умолчанию используется \`TraceContextStore\`\). Таким образом, \`TraceService\` играет ключевую роль в отслеживании и документировании событий прил… -- **plba-v2-explain-create-runtime** - Query: Что делает функция create_runtime? - > Функция \`create\_runtime\` находится в файле \`src/plba/bootstrap.py\`. Она принимает аргумент \`module\`, представляющий экземпляр интерфейса \`ApplicationModule\`. Подтвержденные действия функции: \- Инициализирует объект типа \`RuntimeManager\`. \- Если указан путь к конфигурационному файлу \(\`config\_path\`\), добавляет этот файл в менеджер конфигурации. \- При включённой опции HTTP\-контроля регистрирует канал управления через класс \`HttpControlChannel\`. \- Регистрирует переданный модуль в менеджере. Таким образом, основная задача функции – создать и настроить базовый runtime для приложения. -- **plba-v2-explain-local-http-channel** - Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - > Класс \`HttpControlChannel\` в файле \`http\_channel.py\` реализует канал управления для HTTP\-запросов. В конструкторе \(\`\_\_init\_\_\`\) создаются основные компоненты: \- \`\_runner\`: объект типа \`UvicornThreadRunner\`, управляющий асинхронным сервером uvicorn. \- \`\_factory\`: фабрика приложений типа \`HttpControlAppFactory\`, создающая приложения для обработки запросов. \- \`\_actions\`: коллекция действий управления, инициализируется как \`None\`. Метод \`start\` запускает сервер с приложением, созданным фабрикой, и ожидает завершения работы сервера при вызове \`stop\`. Класс предназначен для организации взаимодействия с внешним миром через HTTP\-интерфейсы. -- **plba-v2-find-tests-runtime-manager** - Query: Где тесты для RuntimeManager? - > Прямые тесты для \`RuntimeManager\` обнаружены в следующих файлах: \- \*\*tests/test\_runtime.py\*\*: проверка инициализации и поведения \`RuntimeManager\`. \- \*\*tests/test\_business\_control\_actions.py\*\*: хотя этот файл упоминает \`RuntimeManager\`, он непосредственно не предназначен для тестирования \`RuntimeManager\`. Вместо этого здесь проверяются контрольные каналы и бизнес\-действия. Косвенных тестов, специфичных для \`RuntimeManager\`, не найдено. -- **plba-v2-find-tests-trace-service** - Query: Где тесты для TraceService? - > Прямые тесты для \`TraceService\` находятся в файле \`tests/test\_runtime.py\`. В следующих функциях проверяются различные аспекты работы \`TraceService\`: \- \`test\_trace\_service\_allows\_messages\_without\_status\`: проверяет корректность записи сообщений без статуса. \- \`test\_trace\_service\_writes\_contexts\_and\_messages\`: проверяет запись контекстов и сообщений. \- \`test\_trace\_service\_supports\_debug\_warning\_and\_error\_levels\`: проверяет поддержку различных уровней логирования. -- **plba-v2-find-tests-create-runtime** - Query: Где тесты для create_runtime? - > Прямых тестов для \`create\_runtime\` не обнаружено. Ближайший тест находится в файле \`tests/test\_runtime.py\`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод \`create\_runtime\`. Косвенное покрытие отсутствует. -- **plba-v2-find-tests-workflow-runtime-factory-negative** - Query: Где тесты для WorkflowRuntimeFactory? - > Insufficient evidence for a confident answer. No test candidates found. -- **plba-v2-find-entrypoints-control-plane** - Query: Найди точки входа HTTP control plane - > Подтверждённые HTTP route points: \- GET /health \(src/app\_runtime/control/http\_app.py:52\) \- POST \(не указан конкретный путь, но находится в src/app\_runtime/control/http\_app.py:38\-42\) \- GET \(повтор, src/app\_runtime/control/http\_app.py:38\-42\) Кандидат на точку входа без явного HTTP route маркера: \- Класс HttpControlChannel в src/app\_runtime/control/http\_channel.py:12\-57, хотя его прямая роль неясна без дополнительного анализа поведения методов start и stop. -- **plba-v2-find-entrypoints-health-endpoint** - Query: Где health endpoint? - > Конкретный health endpoint не обнаружен напрямую. Однако подтверждённые HTTP routes: \- GET / \(объявлен в src/app\_runtime/control/http\_app.py:31\-34\) \- POST / \(объявлен в src/app\_runtime/control/http\_app.py:38\-42\) \- GET / \(повторное объявление в src/app\_runtime/control/http\_app.py:38\-42\) -- **plba-v2-trace-flow-runtime-start** - Query: Покажи поток выполнения при запуске RuntimeManager - > При запуске \`RuntimeManager\` выполняются следующие основные шаги: 1. Инициализация через \`RuntimeManager.\_\_init\_\_\` в файле \`src/app\_runtime/core/runtime.py\`. 2. Вызов метода \`start\` внутри \`RuntimeManager\`, который далее вызывает асинхронную функцию \`\_start\_async\`. 3. В \`ControlPlaneService.start\` создается экземпляр канала управления с помощью метода \`register\_channel\`. 4. Канал управления инициализируется через метод \`start\` экземпляра \`ControlChannel\`, где создается веб\-приложение с использованием фабрики \`HttpControlAppFactory\`. 5. Веб\-приложение запускается с помощью \`UvicornThreadRunner.start\`, который выполняет запуск сервера через uvicorn. Таким образом, поток начинается с инициализации менеджера времени выполнения и завершается запуском веб\-канала управления. -- **plba-v2-trace-flow-health-endpoint** - Query: Покажи как проходит запрос /health в HttpControlAppFactory - > Поток выполнения запроса \`/health\` через \`HttpControlAppFactory\` выглядит следующим образом: 1. Запрос приходит на сервер и обрабатывается фабрикой приложений \`HttpControlAppFactory\`. 2. Внутри фабрики создается экземпляр приложения FastAPI с middleware для логирования времени обработки запросов. 3. Для маршрута \`/health\` определяется обработчик, который вызывает предоставленный провайдер здоровья \(\`health\_provider\`\), ожидающий асинхронный результат типа \`HealthPayload\`. 4. В результате выполнения провайдера формируется JSON\-ответ с кодом статуса 200 при успешном состоянии \("ok"\), иначе возвращается статус 503. Таким образом, ключевой точкой является вызов провайдера здоровья внутри фабрики приложений, от которого зависит итоговый результат ответа. -- **plba-v2-architecture-runtime-manager** - Query: Какие компоненты участвуют в RuntimeManager? - > В подсистеме RuntimeManager участвуют следующие компоненты: 1. \*\*RuntimeManager\*\* \(src/app\_runtime/core/runtime.py\): \- Инициализирует конфигурацию и управляет жизненным циклом runtime\-пipeline. \- Создаёт и регистрирует основные сервисы \(ControlPlaneService, WorkflowPersistence, InMemoryTaskQueue, ConfigFileLoader, TraceContextStore, WorkerSupervisor\). 2. \*\*ControlPlaneService\*\* \(src/app\_runtime/control/service.py\): \- Служба управления каналами контроля и взаимодействия с внешними сущностями. \- Регистрирует каналы и запускает асинхронные операции. 3. \*\*WorkflowPersistence\*\* \(src/app\_runtime/workflow/persistence/workflow\_persistence.py\): \- Обеспечивает долговременное хранение workflow\-данных. 4. \*\*InMemoryTaskQueue\*\* \(src/app\_runtime/queue/in\_memory.py\): \- Хранит задачи в памяти для временного хранения и обработки. 5. \*\*ConfigFileLoader\*\* \(src/app\_runtime/config/file\_l… -- **plba-v2-architecture-control-plane** - Query: Какие компоненты участвуют в ControlPlaneService? - > В архитектуре подсистемы ControlPlaneService участвуют следующие основные компоненты: 1. \*\*ControlPlaneService\*\* – главный сервис, инициализирующий и управляющий каналами контроля. Он создает каналы, регистрирует их и управляет жизненным циклом через методы \`register\_channel\`, \`start\` и \`stop\`. \- Создаёт экземпляры каналов \(\`ControlChannel\`\) и сохраняет их в поле \`\_channels\`. \- Вызывает асинхронную инициализацию каналов с помощью методов \`start\` и \`stop\`. 2. \*\*ControlChannel\*\* – абстрактный базовый класс для каналов управления, определяющий интерфейс для старта и остановки канала. \- Описывает абстракции для начала работы канала и освобождения ресурсов при завершении. 3. \*\*ControlActionSet\*\* – модель действий, используемых в канале управления. Связи между компонентами реализованы следующим образом: \- \*\*ControlPlaneService\*\* создаёт и регистрирует экземпляры каналов уп… -- **plba-v2-explain-nonexistent-symbol** - Query: Объясни класс RuntimeFactoryManager - > Класс \`RuntimeFactoryManager\` не найден в предоставленном контексте. Согласно имеющимся данным, наиболее близкой сущностью является \`ControlChannel\`, объявленный в файле \`base.py\`. Однако его описание и работа напрямую не связаны с созданием или управлением фабриками для runtime. Если предполагается наличие класса с таким названием, возможно, он описан в другом модуле или импортируется из внешнего пакета. Рекомендую проверить остальные части проекта или уточнить местоположение данного класса. -- **plba-v2-open-file-nonexistent** - Query: Открой файл src/app_runtime/core/missing_runtime.py - > Файл \`src/app\_runtime/core/missing\_runtime.py\` не найден. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md deleted file mode 100644 index 4c1abb4..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md +++ /dev/null @@ -1,247 +0,0 @@ -# plba-v2-architecture-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Какие компоненты участвуют в ControlPlaneService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "В системе ControlPlaneService участвуют следующие компоненты:\n\n1. **ControlPlaneService** – главный объект управления, инициализирующий каналы и запускающий асинхронные операции. Он создает и управляет экземплярами каналов, участвующих в управлении данными и событиями.\n - Создаёт каналы с помощью `register_channel`.\n - Запускает и останавливает сервис с помощью методов `start` и `stop`.\n\n2. **ControlChannel** – абстрактный класс для реализации конкретных каналов управления. Подклассами являются HttpControlChannel и WorkerSupervisor.\n - Реализует метод `start`, предназначенный для запуска канала и привязки обработчиков событий.\n - Реализует метод `stop`, используемый для завершения работы и освобождения ресурсов.\n\n3. **HttpControlChannel** – конкретный канал управления HTTP-запросами, участвующий в обработке запросов API.\n - Регистрируется в ControlPlaneService через метод `register_channel`.\n - Обрабатывает входящие запросы с использованием FastAPI.\n\n4. **WorkerSupervisor** – управляет рабочими процессами и координирует выполнение задач.\n - Также регистрируется в ControlPlaneService и участвует в общем управлении системой.\n\nЭти компоненты взаимодействуют через создание и управление каналами, обработку событий и координацию рабочих процессов. Контроль состояния осуществляется через чтение и запись атрибутов состояния.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "ControlPlaneService" - ], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "ARCHITECTURE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 158 - }, - "output": { - "rag_count": 33, - "answer_path_rag_count": 33, - "resolved_symbol_status": "resolved", - "resolved_symbol": "ControlPlaneService", - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C4_SEMANTIC_ROLES": "vector", - "C3_ENTRYPOINTS": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C4_SEMANTIC_ROLES": 12, - "C3_ENTRYPOINTS": 8, - "C2_DEPENDENCY_GRAPH": 8, - "C1_SYMBOL_CATALOG": 6, - "C0_SOURCE_CHUNKS": 4 - }, - "filters_by_layer": { - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 37, - "C3_ENTRYPOINTS": 18, - "C2_DEPENDENCY_GRAPH": 61, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 16 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 2251 - }, - "output": { - "prompt_name": "code_qa_architecture_answer", - "answer_preview": "В системе ControlPlaneService участвуют следующие компоненты:\n\n1. **ControlPlaneService** – главный объект управления, инициализирующий каналы и запускающий асинхронные операции. Он создает и управляет экземплярами каналов, участвующих в управлении данными и событиями.\n - Создаёт каналы с помощью " - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Какие компоненты участвуют в ControlPlaneService?", - "sub_intent": "ARCHITECTURE", - "path_scope": [], - "requested_layers": [ - "C4_SEMANTIC_ROLES", - "C3_ENTRYPOINTS", - "C2_DEPENDENCY_GRAPH", - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 12, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 158, - "pre_evidence_gate": 0, - "llm": 2251 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md deleted file mode 100644 index cf02f94..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md +++ /dev/null @@ -1,247 +0,0 @@ -# plba-v2-explain-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Что делает функция create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Функция `create_runtime` инициализирует объект `RuntimeManager`, загружает конфигурацию из указанного файла (если путь задан), регистрирует HTTP-контроллер для управления состоянием приложения и регистрирует переданный модуль (`ApplicationModule`) в системе.\n\nКонкретно:\n1. Функция создаёт экземпляр `RuntimeManager`.\n2. Если указан путь к файлу конфигурации, файл загружается и добавляется в систему конфигурирования.\n3. При включении опции HTTP-контроллера создаётся и регистрируется соответствующий канал управления через класс `HttpControlChannel`.\n4. Переданный аргумент-модуль регистрируется в системе.\n\nЗависимости и вызовы внутри функции:\n- Загрузка конфигурации через чтение файла и его парсинг (используются библиотеки JSON и YAML).\n- Регистрация модуля в системе конфигурирования через метод `register_module`.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 113 - }, - "output": { - "rag_count": 33, - "answer_path_rag_count": 33, - "resolved_symbol_status": "resolved", - "resolved_symbol": "create_runtime", - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C3_ENTRYPOINTS": 6 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 34, - "C0_SOURCE_CHUNKS": 12, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 42, - "C3_ENTRYPOINTS": 10 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 1394 - }, - "output": { - "prompt_name": "code_qa_explain_answer", - "answer_preview": "Функция `create_runtime` инициализирует объект `RuntimeManager`, загружает конфигурацию из указанного файла (если путь задан), регистрирует HTTP-контроллер для управления состоянием приложения и регистрирует переданный модуль (`ApplicationModule`) в системе.\n\nКонкретно:\n1. Функция создаёт экземпляр " - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Что делает функция create_runtime?", - "sub_intent": "EXPLAIN", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 113, - "pre_evidence_gate": 0, - "llm": 1394 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md deleted file mode 100644 index 636be0b..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md +++ /dev/null @@ -1,223 +0,0 @@ -# plba-v2-explain-local-http-channel - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "EXPLAIN_LOCAL", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` в файле `http_channel.py` реализует канал управления для HTTP-приложения. В конструкторе (`__init__`) инициализируются атрибуты:\n\n- `_timeout`: таймаут для канала.\n- `_runner`: экземпляр `UvicornThreadRunner`, управляющий запуском uvicorn-сервера.\n- `_factory`: фабрика приложений `HttpControlAppFactory`.\n- `_actions`: набор действий (контролируемых операций).\n\nМетод `start` запускает сервер с приложением, созданным фабрикой, и ассоциирует действия с каналом. Метод `stop` останавливает сервер. Класс использует асинхронный подход через аннотации `async`.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "symbol_candidates": [ - "HttpControlChannel" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "EXPLAIN_LOCAL", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 47 - }, - "output": { - "rag_count": 13, - "answer_path_rag_count": 13, - "resolved_symbol_status": "resolved", - "resolved_symbol": "HttpControlChannel", - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] - }, - "diagnostics": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C2_DEPENDENCY_GRAPH": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 12, - "C2_DEPENDENCY_GRAPH": 4 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 23, - "C0_SOURCE_CHUNKS": 11, - "C2_DEPENDENCY_GRAPH": 13 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 1155 - }, - "output": { - "prompt_name": "code_qa_explain_local_answer", - "answer_preview": "Класс `HttpControlChannel` в файле `http_channel.py` реализует канал управления для HTTP-приложения. В конструкторе (`__init__`) инициализируются атрибуты:\n\n- `_timeout`: таймаут для канала.\n- `_runner`: экземпляр `UvicornThreadRunner`, управляющий запуском uvicorn-сервера.\n- `_factory`: фабрика при" - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "EXPLAIN_LOCAL", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", - "sub_intent": "EXPLAIN_LOCAL", - "path_scope": [ - "src/app_runtime/control/http_channel.py" - ], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C2_DEPENDENCY_GRAPH" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 4, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 13 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 47, - "pre_evidence_gate": 0, - "llm": 1155 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md deleted file mode 100644 index ace2a74..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md +++ /dev/null @@ -1,195 +0,0 @@ -# plba-v2-find-entrypoints-control-plane - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Найди точки входа HTTP control plane - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Подтверждённые HTTP route points:\n\n- GET /health (src/app_runtime/control/http_app.py:51)\n- POST (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n- GET (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n\nЭти маршруты объявлены непосредственно в src/app_runtime/control/http_app.py.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "HTTP", - "control", - "plane" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 29 - }, - "output": { - "rag_count": 9, - "answer_path_rag_count": 9, - "resolved_symbol_status": "not_found", - "resolved_symbol": null, - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 - }, - "filters_by_layer": { - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 16 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 853 - }, - "output": { - "prompt_name": "code_qa_find_entrypoints_answer", - "answer_preview": "Подтверждённые HTTP route points:\n\n- GET /health (src/app_runtime/control/http_app.py:51)\n- POST (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n- GET (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n\nЭти маршруты объ" - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_found" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Найди точки входа HTTP control plane", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 9 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 29, - "pre_evidence_gate": 0, - "llm": 853 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md deleted file mode 100644 index 6bacc06..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md +++ /dev/null @@ -1,194 +0,0 @@ -# plba-v2-find-entrypoints-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: False - -## Query -Где health endpoint? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Конкретных health-endpoint'ов, объявленных как routes, не найдено.\n\nОднако, исходя из предоставленного кода:\n- В `http_app.py` есть две явные декларации маршрутов с использованием декоратора `app.get`, но neither из них явно помечен как health-check (метод и путь не указаны).\n- Есть декларация `app.post`, но она также не маркируется как health-related.\n\nТаким образом, хотя health-checking инфраструктура существует (через класс `HealthRegistry`), конкретный health-endpoint не обнаружен среди зарегистрированных маршрутов.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "endpoint" - ], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "FIND_ENTRYPOINTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 46 - }, - "output": { - "rag_count": 9, - "answer_path_rag_count": 9, - "resolved_symbol_status": "not_found", - "resolved_symbol": null, - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 - }, - "filters_by_layer": { - "C3_ENTRYPOINTS": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 28, - "C0_SOURCE_CHUNKS": 18 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 1055 - }, - "output": { - "prompt_name": "code_qa_find_entrypoints_answer", - "answer_preview": "Конкретных health-endpoint'ов, объявленных как routes, не найдено.\n\nОднако, исходя из предоставленного кода:\n- В `http_app.py` есть две явные декларации маршрутов с использованием декоратора `app.get`, но neither из них явно помечен как health-check (метод и путь не указаны).\n- Есть декларация `app." - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_found" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где health endpoint?", - "sub_intent": "FIND_ENTRYPOINTS", - "path_scope": [], - "requested_layers": [ - "C3_ENTRYPOINTS", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 9 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 46, - "pre_evidence_gate": 0, - "llm": 1055 - } -} - -## Mismatches -- llm: expected answer to contain 'GET /health' \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md deleted file mode 100644 index 27c5266..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md +++ /dev/null @@ -1,211 +0,0 @@ -# plba-v2-find-tests-create-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для create_runtime? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Прямых тестов для `create_runtime` не обнаружено. Ближайший тест расположен в файле `tests/test_runtime.py`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод `create_runtime`. Косвенное покрытие отсутствует.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "create_runtime" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 1 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 85 - }, - "output": { - "rag_count": 24, - "answer_path_rag_count": 24, - "resolved_symbol_status": "resolved", - "resolved_symbol": "create_runtime", - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 33, - "C2_DEPENDENCY_GRAPH": 38, - "C0_SOURCE_CHUNKS": 13 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 611 - }, - "output": { - "prompt_name": "code_qa_find_tests_answer", - "answer_preview": "Прямых тестов для `create_runtime` не обнаружено. Ближайший тест расположен в файле `tests/test_runtime.py`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод `create_runtime`. Косвенное покрытие отсутствует." - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для create_runtime?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": { - "router": 1, - "retrieval": 85, - "pre_evidence_gate": 0, - "llm": 611 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md deleted file mode 100644 index 6599fd9..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md +++ /dev/null @@ -1,211 +0,0 @@ -# plba-v2-find-tests-trace-service - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Где тесты для TraceService? - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 24, - "llm_answer": "Прямые тесты для `TraceService` обнаружены в файле `tests/test_runtime.py`. Проверяются следующие аспекты:\n\n- `test_trace_service_allows_messages_without_status`: проверка обработки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверка записи контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверка поддержки различных уровней логирования (DEBUG, WARNING, ERROR).", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "TraceService" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "FIND_TESTS", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 80 - }, - "output": { - "rag_count": 24, - "answer_path_rag_count": 24, - "resolved_symbol_status": "resolved", - "resolved_symbol": "TraceService", - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C0_SOURCE_CHUNKS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C2_DEPENDENCY_GRAPH": 6, - "C0_SOURCE_CHUNKS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 36, - "C2_DEPENDENCY_GRAPH": 31, - "C0_SOURCE_CHUNKS": 12 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 820 - }, - "output": { - "prompt_name": "code_qa_find_tests_answer", - "answer_preview": "Прямые тесты для `TraceService` обнаружены в файле `tests/test_runtime.py`. Проверяются следующие аспекты:\n\n- `test_trace_service_allows_messages_without_status`: проверка обработки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверка записи контекстов и сообщений.\n- " - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для TraceService?", - "sub_intent": "FIND_TESTS", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C2_DEPENDENCY_GRAPH", - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 10, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 24 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 80, - "pre_evidence_gate": 0, - "llm": 820 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md deleted file mode 100644 index f6c7dcc..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md +++ /dev/null @@ -1,188 +0,0 @@ -# plba-v2-open-file-public-api - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/plba/__init__.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "В файле src/plba/__init__.py видны следующие импорты и объявления:\n\n- from plba.bootstrap import create_runtime\n- from plba.config import ConfigFileLoader, FileConfigProvider\n- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\n- from plba.contracts import ApplicationModule, ConfigProvider, HealthContributor, TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport, Worker, WorkerHealth, WorkerStatus\n- from plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\n- from plba.health import HealthRegistry\n- from plba.logging import LogManager\n- from plba.queue import InMemoryTaskQueue\n- from plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\n- from plba.workflow import StepResult, WorkflowContext, WorkflowDefinition, Workflo", - "answer_mode": "answered", - "path_scope": [ - "src/plba/__init__.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 24 - }, - "output": { - "rag_count": 1, - "answer_path_rag_count": 1, - "resolved_symbol_status": "not_requested", - "resolved_symbol": null, - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C0_SOURCE_CHUNKS": "exact_path_fetch" - }, - "top_k_by_layer": { - "C0_SOURCE_CHUNKS": 200 - }, - "filters_by_layer": { - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/plba/__init__.py" - ] - } - }, - "requests": [ - { - "layer": "C0_SOURCE_CHUNKS", - "query": "Открой файл src/plba/__init__.py", - "ranking_profile": "code" - } - ], - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 24 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 1406 - }, - "output": { - "prompt_name": "code_qa_open_file_answer", - "answer_preview": "В файле src/plba/__init__.py видны следующие импорты и объявления:\n\n- from plba.bootstrap import create_runtime\n- from plba.config import ConfigFileLoader, FileConfigProvider\n- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\n- from plba.contracts im" - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "layers": [ - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_requested" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/plba/__init__.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/plba/__init__.py" - ], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 1 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 24, - "pre_evidence_gate": 0, - "llm": 1406 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md deleted file mode 100644 index 6aa40ba..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md +++ /dev/null @@ -1,188 +0,0 @@ -# plba-v2-open-file-runtime - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Открой файл src/app_runtime/core/runtime.py - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 1, - "llm_answer": "Виден класс `RuntimeManager` с методом `__init__`, принимающим несколько параметров. Фиксированы также константы `ACTION_TIMEOUT_SECONDS` и `ACTION_POLL_INTERVAL_SECONDS`.", - "answer_mode": "answered", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "symbol_candidates": [], - "layers": [ - "C0_SOURCE_CHUNKS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "OPEN_FILE", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 221 - }, - "output": { - "rag_count": 1, - "answer_path_rag_count": 1, - "resolved_symbol_status": "not_requested", - "resolved_symbol": null, - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_mode_by_layer": { - "C0_SOURCE_CHUNKS": "exact_path_fetch" - }, - "top_k_by_layer": { - "C0_SOURCE_CHUNKS": 200 - }, - "filters_by_layer": { - "C0_SOURCE_CHUNKS": { - "path_scope": [ - "src/app_runtime/core/runtime.py" - ] - } - }, - "requests": [ - { - "layer": "C0_SOURCE_CHUNKS", - "query": "Открой файл src/app_runtime/core/runtime.py", - "ranking_profile": "code" - } - ], - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 221 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 578 - }, - "output": { - "prompt_name": "code_qa_open_file_answer", - "answer_preview": "Виден класс `RuntimeManager` с методом `__init__`, принимающим несколько параметров. Фиксированы также константы `ACTION_TIMEOUT_SECONDS` и `ACTION_POLL_INTERVAL_SECONDS`." - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C0_SOURCE_CHUNKS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "layers": [ - "C0_SOURCE_CHUNKS" - ], - "symbol_resolution_status": "not_requested" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Открой файл src/app_runtime/core/runtime.py", - "sub_intent": "OPEN_FILE", - "path_scope": [ - "src/app_runtime/core/runtime.py" - ], - "requested_layers": [ - "C0_SOURCE_CHUNKS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 1, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 1 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 221, - "pre_evidence_gate": 0, - "llm": 578 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md deleted file mode 100644 index 6cafd6c..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md +++ /dev/null @@ -1,248 +0,0 @@ -# plba-v2-trace-flow-health-endpoint - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи как проходит запрос /health в HttpControlAppFactory - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "Поток выполнения запроса `/health` в `HttpControlAppFactory` выглядит следующим образом:\n\n1. Запрос приходит на маршрут `/health`.\n2. Контроллер вызывает метод `health()` внутри фабрики, который объявлен в классе `HttpControlAppFactory`.\n3. Внутри метода `health()` фабрика ожидает асинхронный результат от провайдера здоровья (`health_provider`), представляющего состояние системы.\n4. Результат передается в виде объекта `HealthPayload`, содержащего статус (\"ok\" или иное).\n5. На основе статуса определяется HTTP-код ответа: 200 при успешном состоянии, иначе 503.\n6. Ответ формируется с использованием JSON формата.\n\nТаким образом, ключевой элемент — провайдер здоровья, определяющий текущее состояние системы и возвращающий соответствующий объект состояния.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "health", - "HttpControlAppFactory" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 169 - }, - "output": { - "rag_count": 37, - "answer_path_rag_count": 37, - "resolved_symbol_status": "resolved", - "resolved_symbol": "HttpControlAppFactory", - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 10, - "C3_ENTRYPOINTS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 55, - "C0_SOURCE_CHUNKS": 28, - "C4_SEMANTIC_ROLES": 17, - "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 11 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 1342 - }, - "output": { - "prompt_name": "code_qa_trace_flow_answer", - "answer_preview": "Поток выполнения запроса `/health` в `HttpControlAppFactory` выглядит следующим образом:\n\n1. Запрос приходит на маршрут `/health`.\n2. Контроллер вызывает метод `health()` внутри фабрики, который объявлен в классе `HttpControlAppFactory`.\n3. Внутри метода `health()` фабрика ожидает асинхронный резуль" - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи как проходит запрос /health в HttpControlAppFactory", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 37 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 169, - "pre_evidence_gate": 0, - "llm": 1342 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md deleted file mode 100644 index e2688c2..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md +++ /dev/null @@ -1,247 +0,0 @@ -# plba-v2-trace-flow-runtime-start - -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml -- runner: agent_runtime -- mode: full_chain -- passed: True - -## Query -Покажи поток выполнения при запуске RuntimeManager - -## Actual -{ - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "rag_count": 37, - "llm_answer": "При запуске `RuntimeManager` выполняются следующие основные шаги:\n\n1. В `bootstrap.py` создаётся экземпляр `RuntimeManager`.\n2. В `core/runtime.py` инициализируется объект `RuntimeManager`, вызывая его конструктор.\n3. Далее выполняется регистрация базовых сервисов через метод `_register_core_services`.\n4. Запускаются каналы управления с помощью метода `start` объекта `ControlPlaneService`.\n5. Каналы управления начинают свою работу через асинхронный запуск метода `_start_async`.\n6. Управление веб-приложением осуществляется через создание экземпляра `HttpControlChannel`, который использует сервер `UvicornThreadRunner` для запуска HTTP приложения.\n\nПолностью проследить весь поток данных не удалось из-за недостаточного количества информации.", - "answer_mode": "answered", - "path_scope": [], - "symbol_candidates": [ - "RuntimeManager" - ], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] -} - -## Steps -[ - { - "step": "router", - "status": "completed", - "timings_ms": { - "router": 0 - }, - "output": { - "intent": "CODE_QA", - "sub_intent": "TRACE_FLOW", - "graph_id": "CodeQAGraph", - "conversation_mode": "START" - } - }, - { - "step": "retrieval", - "status": "completed", - "timings_ms": { - "retrieval": 153 - }, - "output": { - "rag_count": 37, - "answer_path_rag_count": 37, - "resolved_symbol_status": "resolved", - "resolved_symbol": "RuntimeManager", - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "diagnostics": { - "executed_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_mode_by_layer": { - "C1_SYMBOL_CATALOG": "vector", - "C0_SOURCE_CHUNKS": "vector", - "C4_SEMANTIC_ROLES": "vector", - "C2_DEPENDENCY_GRAPH": "vector", - "C3_ENTRYPOINTS": "vector" - }, - "top_k_by_layer": { - "C1_SYMBOL_CATALOG": 8, - "C0_SOURCE_CHUNKS": 8, - "C4_SEMANTIC_ROLES": 8, - "C2_DEPENDENCY_GRAPH": 10, - "C3_ENTRYPOINTS": 10 - }, - "filters_by_layer": { - "C1_SYMBOL_CATALOG": { - "path_scope": [] - }, - "C0_SOURCE_CHUNKS": { - "path_scope": [] - }, - "C4_SEMANTIC_ROLES": { - "path_scope": [] - }, - "C2_DEPENDENCY_GRAPH": { - "path_scope": [] - }, - "C3_ENTRYPOINTS": { - "path_scope": [] - } - }, - "fallback": { - "used": false, - "reason": null - }, - "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 39, - "C0_SOURCE_CHUNKS": 24, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 20 - } - } - }, - { - "step": "pre_evidence_gate", - "status": "passed", - "timings_ms": { - "pre_evidence_gate": 0 - }, - "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" - } - }, - { - "step": "llm", - "status": "completed", - "timings_ms": { - "llm": 1356 - }, - "output": { - "prompt_name": "code_qa_trace_flow_answer", - "answer_preview": "При запуске `RuntimeManager` выполняются следующие основные шаги:\n\n1. В `bootstrap.py` создаётся экземпляр `RuntimeManager`.\n2. В `core/runtime.py` инициализируется объект `RuntimeManager`, вызывая его конструктор.\n3. Далее выполняется регистрация базовых сервисов через метод `_register_core_service" - } - }, - { - "step": "post_evidence_gate", - "status": "passed", - "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 - }, - "output": { - "passed": true, - "reasons": [], - "repair_used": false - } - } -] - -## Diagnostics -{ - "intent_correct": null, - "target_found": true, - "layers_used": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "retrieval_sufficient": true, - "answer_mode": "normal", - "router_result": { - "intent": "CODE_QA", - "graph_id": "CodeQAGraph", - "conversation_mode": "START", - "retrieval_profile": "code", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ], - "symbol_resolution_status": "resolved" - }, - "retrieval_request": { - "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Покажи поток выполнения при запуске RuntimeManager", - "sub_intent": "TRACE_FLOW", - "path_scope": [], - "requested_layers": [ - "C1_SYMBOL_CATALOG", - "C0_SOURCE_CHUNKS", - "C4_SEMANTIC_ROLES", - "C2_DEPENDENCY_GRAPH", - "C3_ENTRYPOINTS" - ] - }, - "per_layer_outcome": [ - { - "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 10, - "empty": false, - "fallback_used": false - }, - { - "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, - "fallback_used": false - } - ], - "empty_layers": [], - "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 37 - }, - "failure_reasons": [], - "timings_ms": { - "router": 0, - "retrieval": 153, - "pre_evidence_gate": 0, - "llm": 1356 - } -} - -## Mismatches -- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/summary.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/summary.md deleted file mode 100644 index 3780ae5..0000000 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/summary.md +++ /dev/null @@ -1,84 +0,0 @@ -# pipeline_setup_v3 summary - -Passed: 16/18 - -| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | -|------|------|------|-------|-------------------|------------|------| -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-public-api | full_chain | Открой файл src/plba/__init__.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-trace-service | full_chain | Объясни как работает класс TraceService | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-create-runtime | full_chain | Что делает функция create_runtime? | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-trace-service | full_chain | Где тесты для TraceService? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-create-runtime | full_chain | Где тесты для create_runtime? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-workflow-runtime-factory-negative | full_chain | Где тесты для WorkflowRuntimeFactory? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-control-plane | full_chain | Найди точки входа HTTP control plane | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-health-endpoint | full_chain | Покажи как проходит запрос /health в HttpControlAppFactory | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-control-plane | full_chain | Какие компоненты участвуют в ControlPlaneService? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | — | ✗ | -| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✓ | - -## Failures -- **plba-v2-find-entrypoints-health-endpoint**: llm: expected answer to contain 'GET /health' -- **plba-v2-explain-nonexistent-symbol**: llm: expected answer to contain 'не найдена' - -## LLM Answers -- **plba-v2-open-file-runtime** - Query: Открой файл src/app_runtime/core/runtime.py - > Виден класс \`RuntimeManager\` с методом \`\_\_init\_\_\`, принимающим несколько параметров. Фиксированы также константы \`ACTION\_TIMEOUT\_SECONDS\` и \`ACTION\_POLL\_INTERVAL\_SECONDS\`. -- **plba-v2-open-file-public-api** - Query: Открой файл src/plba/__init__.py - > В файле src/plba/\_\_init\_\_.py видны следующие импорты и объявления: \- from plba.bootstrap import create\_runtime \- from plba.config import ConfigFileLoader, FileConfigProvider \- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel \- from plba.contracts import ApplicationModule, ConfigProvider, HealthContributor, TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport, Worker, WorkerHealth, WorkerStatus \- from plba.core import ConfigurationManager, RuntimeManager, ServiceContainer \- from plba.health import HealthRegistry \- from plba.logging import LogManager \- from plba.queue import InMemoryTaskQueue \- from plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService \- from plba.workflow import StepResult, WorkflowContext, WorkflowDefinition, Workflo -- **plba-v2-explain-runtime-manager** - Query: Объясни как работает класс RuntimeManager - > Класс \`RuntimeManager\` находится в файле \`src/app\_runtime/core/runtime.py\`. Конкретной реализации инициализации или подробного описания методов в предоставленном контексте не видно. Однако исходя из имеющихся признаков: 1. Класс имеет ответственность за управление состоянием и конфигурацией runtime\-системы, судя по названиям атрибутов и методов в окружении \(\`configuration\`, \`add\_config\_file\`\). 2. Вероятно, он участвует в оркестрации различных компонентов системы через свои методы и атрибуты, хотя детальной информации об этих методах и атрибутах нет. Таким образом, класс \`RuntimeManager\` играет ключевую управляющую роль в системе, вероятно, интегрируя и координируя другие компоненты и модули. -- **plba-v2-explain-trace-service** - Query: Объясни как работает класс TraceService - > Класс \`TraceService\` определяется в файле \`src/app\_runtime/tracing/service.py\`. Он наследует от \`TraceContextFactory\`. Его основные обязанности: \- Инициализация при создании через параметры \`transport\` и \`store\`, с возможностью использования стандартных реализаций \(\`NoOpTraceTransport\` и \`TraceContextStore\`\). \- Метод \`create\_context\` создаёт новый контекст трассировки с заданными параметрами и записывает его в хранилище. \- Методы \`current\_trace\_id\` и \`step\` предоставляют доступ к текущему идентификатору трассы и выполняют дополнительные действия. Детали реализации зависят от конкретных методов, таких как инициализация транспорта и контекста, а также запись записей трассировки в хранилище. -- **plba-v2-explain-create-runtime** - Query: Что делает функция create_runtime? - > Функция \`create\_runtime\` инициализирует объект \`RuntimeManager\`, загружает конфигурацию из указанного файла \(если путь задан\), регистрирует HTTP\-контроллер для управления состоянием приложения и регистрирует переданный модуль \(\`ApplicationModule\`\) в системе. Конкретно: 1. Функция создаёт экземпляр \`RuntimeManager\`. 2. Если указан путь к файлу конфигурации, файл загружается и добавляется в систему конфигурирования. 3. При включении опции HTTP\-контроллера создаётся и регистрируется соответствующий канал управления через класс \`HttpControlChannel\`. 4. Переданный аргумент\-модуль регистрируется в системе. Зависимости и вызовы внутри функции: \- Загрузка конфигурации через чтение файла и его парсинг \(используются библиотеки JSON и YAML\). \- Регистрация модуля в системе конфигурирования через метод \`register\_module\`. -- **plba-v2-explain-local-http-channel** - Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? - > Класс \`HttpControlChannel\` в файле \`http\_channel.py\` реализует канал управления для HTTP\-приложения. В конструкторе \(\`\_\_init\_\_\`\) инициализируются атрибуты: \- \`\_timeout\`: таймаут для канала. \- \`\_runner\`: экземпляр \`UvicornThreadRunner\`, управляющий запуском uvicorn\-сервера. \- \`\_factory\`: фабрика приложений \`HttpControlAppFactory\`. \- \`\_actions\`: набор действий \(контролируемых операций\). Метод \`start\` запускает сервер с приложением, созданным фабрикой, и ассоциирует действия с каналом. Метод \`stop\` останавливает сервер. Класс использует асинхронный подход через аннотации \`async\`. -- **plba-v2-find-tests-runtime-manager** - Query: Где тесты для RuntimeManager? - > Прямые тесты для \`RuntimeManager\` находятся в файле \`tests/test\_runtime.py\`. Эти тесты проверяют инициализацию и поведение объекта \`RuntimeManager\`. Косвенных тестов, явно связанных с \`RuntimeManager\`, больше нигде не обнаружено. -- **plba-v2-find-tests-trace-service** - Query: Где тесты для TraceService? - > Прямые тесты для \`TraceService\` обнаружены в файле \`tests/test\_runtime.py\`. Проверяются следующие аспекты: \- \`test\_trace\_service\_allows\_messages\_without\_status\`: проверка обработки сообщений без статуса. \- \`test\_trace\_service\_writes\_contexts\_and\_messages\`: проверка записи контекстов и сообщений. \- \`test\_trace\_service\_supports\_debug\_warning\_and\_error\_levels\`: проверка поддержки различных уровней логирования \(DEBUG, WARNING, ERROR\). -- **plba-v2-find-tests-create-runtime** - Query: Где тесты для create_runtime? - > Прямых тестов для \`create\_runtime\` не обнаружено. Ближайший тест расположен в файле \`tests/test\_runtime.py\`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод \`create\_runtime\`. Косвенное покрытие отсутствует. -- **plba-v2-find-tests-workflow-runtime-factory-negative** - Query: Где тесты для WorkflowRuntimeFactory? - > Insufficient evidence for a confident answer. No test candidates found. -- **plba-v2-find-entrypoints-control-plane** - Query: Найди точки входа HTTP control plane - > Подтверждённые HTTP route points: \- GET /health \(src/app\_runtime/control/http\_app.py:51\) \- POST \(не указан путь, только декорированный метод в src/app\_runtime/control/http\_app.py:38\-42\) \- GET \(не указан путь, только декорированный метод в src/app\_runtime/control/http\_app.py:38\-42\) Эти маршруты объявлены непосредственно в src/app\_runtime/control/http\_app.py. -- **plba-v2-find-entrypoints-health-endpoint** - Query: Где health endpoint? - > Конкретных health\-endpoint'ов, объявленных как routes, не найдено. Однако, исходя из предоставленного кода: \- В \`http\_app.py\` есть две явные декларации маршрутов с использованием декоратора \`app.get\`, но neither из них явно помечен как health\-check \(метод и путь не указаны\). \- Есть декларация \`app.post\`, но она также не маркируется как health\-related. Таким образом, хотя health\-checking инфраструктура существует \(через класс \`HealthRegistry\`\), конкретный health\-endpoint не обнаружен среди зарегистрированных маршрутов. -- **plba-v2-trace-flow-runtime-start** - Query: Покажи поток выполнения при запуске RuntimeManager - > При запуске \`RuntimeManager\` выполняются следующие основные шаги: 1. В \`bootstrap.py\` создаётся экземпляр \`RuntimeManager\`. 2. В \`core/runtime.py\` инициализируется объект \`RuntimeManager\`, вызывая его конструктор. 3. Далее выполняется регистрация базовых сервисов через метод \`\_register\_core\_services\`. 4. Запускаются каналы управления с помощью метода \`start\` объекта \`ControlPlaneService\`. 5. Каналы управления начинают свою работу через асинхронный запуск метода \`\_start\_async\`. 6. Управление веб\-приложением осуществляется через создание экземпляра \`HttpControlChannel\`, который использует сервер \`UvicornThreadRunner\` для запуска HTTP приложения. Полностью проследить весь поток данных не удалось из\-за недостаточного количества информации. -- **plba-v2-trace-flow-health-endpoint** - Query: Покажи как проходит запрос /health в HttpControlAppFactory - > Поток выполнения запроса \`/health\` в \`HttpControlAppFactory\` выглядит следующим образом: 1. Запрос приходит на маршрут \`/health\`. 2. Контроллер вызывает метод \`health\(\)\` внутри фабрики, который объявлен в классе \`HttpControlAppFactory\`. 3. Внутри метода \`health\(\)\` фабрика ожидает асинхронный результат от провайдера здоровья \(\`health\_provider\`\), представляющего состояние системы. 4. Результат передается в виде объекта \`HealthPayload\`, содержащего статус \("ok" или иное\). 5. На основе статуса определяется HTTP\-код ответа: 200 при успешном состоянии, иначе 503. 6. Ответ формируется с использованием JSON формата. Таким образом, ключевой элемент — провайдер здоровья, определяющий текущее состояние системы и возвращающий соответствующий объект состояния. -- **plba-v2-architecture-runtime-manager** - Query: Какие компоненты участвуют в RuntimeManager? - > В подсистеме RuntimeManager участвуют следующие компоненты: 1. \*\*RuntimeManager\*\* — главный менеджер runtime, отвечает за конфигурацию и запуск runtime\-потоков \(src/app\_runtime/core/runtime.py\). 2. \*\*ControlPlaneService\*\* — сервис управления каналами контроля, обеспечивает регистрацию каналов и старт/стоп операций \(src/app\_runtime/control/service.py\). 3. \*\*ControlChannel\*\* — абстрактный канал управления, определяющий интерфейсы для запуска и остановки канала \(src/app\_runtime/control/base.py\). 4. \*\*UvicornThreadRunner\*\* — реализует uvicorn thread runner для обработки HTTP\-запросов \(src/app\_runtime/control/http\_runner.py\). 5. \*\*HttpControlChannel\*\* — HTTP\-канал управления, участвует в управлении состояниями и операциях \(src/app\_runtime/control/http\_channel.py\). 6. \*\*HttpControlAppFactory\*\* — фабрика для создания fastAPI приложений с контролем состояний \(src/app\_runtime… -- **plba-v2-architecture-control-plane** - Query: Какие компоненты участвуют в ControlPlaneService? - > В системе ControlPlaneService участвуют следующие компоненты: 1. \*\*ControlPlaneService\*\* – главный объект управления, инициализирующий каналы и запускающий асинхронные операции. Он создает и управляет экземплярами каналов, участвующих в управлении данными и событиями. \- Создаёт каналы с помощью \`register\_channel\`. \- Запускает и останавливает сервис с помощью методов \`start\` и \`stop\`. 2. \*\*ControlChannel\*\* – абстрактный класс для реализации конкретных каналов управления. Подклассами являются HttpControlChannel и WorkerSupervisor. \- Реализует метод \`start\`, предназначенный для запуска канала и привязки обработчиков событий. \- Реализует метод \`stop\`, используемый для завершения работы и освобождения ресурсов. 3. \*\*HttpControlChannel\*\* – конкретный канал управления HTTP\-запросами, участвующий в обработке запросов API. \- Регистрируется в ControlPlaneService через метод \`r… -- **plba-v2-explain-nonexistent-symbol** - Query: Объясни класс RuntimeFactoryManager - > Сущность не удалось однозначно разрешить. Близкие варианты: ControlChannel, ControlChannel.stop, ControlActionSet. -- **plba-v2-open-file-nonexistent** - Query: Открой файл src/app_runtime/core/missing_runtime.py - > Файл src/app\_runtime/core/missing\_runtime.py не найден. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json similarity index 95% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json index ba60c23..f6b7b73 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-architecture-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Какие компоненты участвуют в ControlPlaneService?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "В системе ControlPlaneService участвуют следующие компоненты:\n\n1. **ControlPlaneService** – главный объект управления, инициализирующий каналы и запускающий асинхронные операции. Он создает и управляет экземплярами каналов, участвующих в управлении данными и событиями.\n - Создаёт каналы с помощью `register_channel`.\n - Запускает и останавливает сервис с помощью методов `start` и `stop`.\n\n2. **ControlChannel** – абстрактный класс для реализации конкретных каналов управления. Подклассами являются HttpControlChannel и WorkerSupervisor.\n - Реализует метод `start`, предназначенный для запуска канала и привязки обработчиков событий.\n - Реализует метод `stop`, используемый для завершения работы и освобождения ресурсов.\n\n3. **HttpControlChannel** – конкретный канал управления HTTP-запросами, участвующий в обработке запросов API.\n - Регистрируется в ControlPlaneService через метод `register_channel`.\n - Обрабатывает входящие запросы с использованием FastAPI.\n\n4. **WorkerSupervisor** – управляет рабочими процессами и координирует выполнение задач.\n - Также регистрируется в ControlPlaneService и участвует в общем управлении системой.\n\nЭти компоненты взаимодействуют через создание и управление каналами, обработку событий и координацию рабочих процессов. Контроль состояния осуществляется через чтение и запись атрибутов состояния.", + "llm_answer": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlChannel** – канал HTTP-контроля, этап пайплайна.\n- **HttpControlAppFactory** – фабрика создания HTTP-приложения контроля.\n- **WorkflowPersistence** – сохранение состояний рабочих процессов.\n- **InMemoryTaskQueue** – очередь задач в памяти.\n- **ConfigFileLoader** – загрузчик конфигурационных файлов.\n- **TraceContextStore** – хранилище контекстов трассировки.\n- **WorkerSupervisor** – надзор за рабочими процессами.\n- **WorkflowEngine** – движок обработки рабочих процессов.\n\nСвязи внутри ControlPlaneService:\n\n- _channels – атрибут, используемый во многих методах сервиса.\n- register_channel() – метод регистрации канала контроля.\n- start(), stop() – методы старта и остановки сервиса асинхронно.\n\nГраницы ответственности ControlPlaneService подтверждаются инициализацией, регистрацией каналов и управлением жизненным циклом сервисов.\n\nФайлы с ключевыми реализациями: \n- src/app_runtime/control/service.py\n- src/app_runtime/control/base.py\n- src/app_runtime/control/http_runner.py\n- src/app_runtime/control/http_channel.py\n- src/app_runtime/control/http_app.py\n\nВызовы fastapi app.post и app.get используются для HTTP-обработки действий контроля.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1534,36 +1534,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1591,6 +1571,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1614,6 +1601,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2885,11 +2906,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 37, - "C3_ENTRYPOINTS": 18, + "C4_SEMANTIC_ROLES": 57, + "C3_ENTRYPOINTS": 14, "C2_DEPENDENCY_GRAPH": 61, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 16 + "C1_SYMBOL_CATALOG": 25, + "C0_SOURCE_CHUNKS": 17 } } }, @@ -2905,6 +2926,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2972,12 +2996,41 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 158, - "pre_evidence_gate": 0, - "llm": 2251 + "router": 1, + "retrieval": 177, + "pre_evidence_gate": 1, + "llm": 6818, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -4181,7 +4234,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -4194,7 +4247,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 158 + "retrieval": 177 }, "output": { "rag_count": 33, @@ -4253,11 +4306,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 37, - "C3_ENTRYPOINTS": 18, + "C4_SEMANTIC_ROLES": 57, + "C3_ENTRYPOINTS": 14, "C2_DEPENDENCY_GRAPH": 61, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 16 + "C1_SYMBOL_CATALOG": 25, + "C0_SOURCE_CHUNKS": 17 } } }, @@ -4265,36 +4318,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 33 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 2251 + "llm": 6818 }, "output": { "prompt_name": "code_qa_architecture_answer", - "answer_preview": "В системе ControlPlaneService участвуют следующие компоненты:\n\n1. **ControlPlaneService** – главный объект управления, инициализирующий каналы и запускающий асинхронные операции. Он создает и управляет экземплярами каналов, участвующих в управлении данными и событиями.\n - Создаёт каналы с помощью " + "answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md new file mode 100644 index 0000000..e6b24a9 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md @@ -0,0 +1,305 @@ +# plba-v2-architecture-control-plane + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Какие компоненты участвуют в ControlPlaneService? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlChannel** – канал HTTP-контроля, этап пайплайна.\n- **HttpControlAppFactory** – фабрика создания HTTP-приложения контроля.\n- **WorkflowPersistence** – сохранение состояний рабочих процессов.\n- **InMemoryTaskQueue** – очередь задач в памяти.\n- **ConfigFileLoader** – загрузчик конфигурационных файлов.\n- **TraceContextStore** – хранилище контекстов трассировки.\n- **WorkerSupervisor** – надзор за рабочими процессами.\n- **WorkflowEngine** – движок обработки рабочих процессов.\n\nСвязи внутри ControlPlaneService:\n\n- _channels – атрибут, используемый во многих методах сервиса.\n- register_channel() – метод регистрации канала контроля.\n- start(), stop() – методы старта и остановки сервиса асинхронно.\n\nГраницы ответственности ControlPlaneService подтверждаются инициализацией, регистрацией каналов и управлением жизненным циклом сервисов.\n\nФайлы с ключевыми реализациями: \n- src/app_runtime/control/service.py\n- src/app_runtime/control/base.py\n- src/app_runtime/control/http_runner.py\n- src/app_runtime/control/http_channel.py\n- src/app_runtime/control/http_app.py\n\nВызовы fastapi app.post и app.get используются для HTTP-обработки действий контроля.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "ControlPlaneService" + ], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 177 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "ControlPlaneService", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 57, + "C3_ENTRYPOINTS": 14, + "C2_DEPENDENCY_GRAPH": 61, + "C1_SYMBOL_CATALOG": 25, + "C0_SOURCE_CHUNKS": 17 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 6818 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Какие компоненты участвуют в ControlPlaneService?", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 12, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в ControlPlaneService:\n\n- **ControlActionSet** – модель для управления действиями.\n- **ControlChannel** – абстрактный базовый класс каналов контроля с методами start и stop.\n- **UvicornThreadRunner** – этап пайплайна для многопоточного запуска HTTP сервера.\n- **HttpControlCha" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 177, + "pre_evidence_gate": 1, + "llm": 6818, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json similarity index 95% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json index 1e733da..5bafbcb 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-architecture-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Какие компоненты участвуют в RuntimeManager?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "В подсистеме RuntimeManager участвуют следующие компоненты:\n\n1. **RuntimeManager** — главный менеджер runtime, отвечает за конфигурацию и запуск runtime-потоков (src/app_runtime/core/runtime.py).\n2. **ControlPlaneService** — сервис управления каналами контроля, обеспечивает регистрацию каналов и старт/стоп операций (src/app_runtime/control/service.py).\n3. **ControlChannel** — абстрактный канал управления, определяющий интерфейсы для запуска и остановки канала (src/app_runtime/control/base.py).\n4. **UvicornThreadRunner** — реализует uvicorn thread runner для обработки HTTP-запросов (src/app_runtime/control/http_runner.py).\n5. **HttpControlChannel** — HTTP-канал управления, участвует в управлении состояниями и операциях (src/app_runtime/control/http_channel.py).\n6. **HttpControlAppFactory** — фабрика для создания fastAPI приложений с контролем состояний (src/app_runtime/control/http_app.py).\n7. **WorkflowPersistence** — сохраняет состояние workflow-потоков (src/app_runtime/workflow/persistence/workflow_persistence.py).\n8. **InMemoryTaskQueue** — очередь задач в памяти, используется для хранения и обработки заданий (src/app_runtime/queue/in_memory.py).\n9. **ConfigFileLoader** — загружает конфигурации из файлов (src/app_runtime/config/file_loader.py).\n10. **TraceContextStore** — хранит контекст трассировки для отслеживания выполнения потоков (src/app_runtime/tracing/store.py).\n11. **WorkerSupervisor** — управляет рабочими процессами и их мониторингом (src/app_runtime/workers/supervisor.py).\n\nВсе эти компоненты взаимодействуют через общую инфраструктуру runtime, обмениваясь данными и событиями, участвуя в общем потоке управления и исполнения задач.", + "llm_answer": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для создания HTTP-приложений контроля. \n - Файл: `http_app.py` (строки 15–53).\n\n3. **UvicornThreadRunner** \n - Выполняет работу в потоке Uvicorn. \n - Файл: `http_runner.py` (строки 10–61).\n\n4. **HttpControlChannel** \n - Канал HTTP-контроля. \n - Файл: `http_channel.py` (строки 12–57).\n\n5. **WorkflowPersistence** \n - Сохраняет состояние рабочих процессов. \n - Файл: `workflow_persistence.py` (строки 8–54).\n\n6. **InMemoryTaskQueue** \n - Очередь задач в памяти. \n - Файл: `in_memory.py` (строки 9–38).\n\n7. **ConfigFileLoader** \n - Загружает конфигурационные файлы. \n - Файл: `file_loader.py` (строки 11–48).\n\n8. **TraceContextStore** \n - Хранит контекст трассировки. \n - Файл: `store.py` (строки 15–52).\n\n9. **WorkerSupervisor** \n - Наблюдатель за рабочими процессами. \n - Файл: `supervisor.py` (строки 10–59).\n\nСвязи внутри конструктора RuntimeManager включают инициализацию конфигурации, регистрацию сервисов и добавление конфигурационных файлов. \nФайл: `runtime.py`, строки 32–127.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1630,36 +1630,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1687,6 +1667,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1710,6 +1697,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3030,10 +3051,10 @@ }, "retrieval_by_layer_ms": { "C4_SEMANTIC_ROLES": 33, - "C3_ENTRYPOINTS": 19, - "C2_DEPENDENCY_GRAPH": 61, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 15 + "C3_ENTRYPOINTS": 16, + "C2_DEPENDENCY_GRAPH": 67, + "C1_SYMBOL_CATALOG": 36, + "C0_SOURCE_CHUNKS": 24 } } }, @@ -3049,6 +3070,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3116,12 +3140,41 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 155, - "pre_evidence_gate": 0, - "llm": 2995 + "router": 1, + "retrieval": 178, + "pre_evidence_gate": 1, + "llm": 9368, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -4373,7 +4426,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -4386,7 +4439,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 155 + "retrieval": 178 }, "output": { "rag_count": 33, @@ -4446,10 +4499,10 @@ }, "retrieval_by_layer_ms": { "C4_SEMANTIC_ROLES": 33, - "C3_ENTRYPOINTS": 19, - "C2_DEPENDENCY_GRAPH": 61, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 15 + "C3_ENTRYPOINTS": 16, + "C2_DEPENDENCY_GRAPH": 67, + "C1_SYMBOL_CATALOG": 36, + "C0_SOURCE_CHUNKS": 24 } } }, @@ -4457,36 +4510,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 33 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 2995 + "llm": 9368 }, "output": { "prompt_name": "code_qa_architecture_answer", - "answer_preview": "В подсистеме RuntimeManager участвуют следующие компоненты:\n\n1. **RuntimeManager** — главный менеджер runtime, отвечает за конфигурацию и запуск runtime-потоков (src/app_runtime/core/runtime.py).\n2. **ControlPlaneService** — сервис управления каналами контроля, обеспечивает регистрацию каналов и ста" + "answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md new file mode 100644 index 0000000..1d63690 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md @@ -0,0 +1,305 @@ +# plba-v2-architecture-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Какие компоненты участвуют в RuntimeManager? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для создания HTTP-приложений контроля. \n - Файл: `http_app.py` (строки 15–53).\n\n3. **UvicornThreadRunner** \n - Выполняет работу в потоке Uvicorn. \n - Файл: `http_runner.py` (строки 10–61).\n\n4. **HttpControlChannel** \n - Канал HTTP-контроля. \n - Файл: `http_channel.py` (строки 12–57).\n\n5. **WorkflowPersistence** \n - Сохраняет состояние рабочих процессов. \n - Файл: `workflow_persistence.py` (строки 8–54).\n\n6. **InMemoryTaskQueue** \n - Очередь задач в памяти. \n - Файл: `in_memory.py` (строки 9–38).\n\n7. **ConfigFileLoader** \n - Загружает конфигурационные файлы. \n - Файл: `file_loader.py` (строки 11–48).\n\n8. **TraceContextStore** \n - Хранит контекст трассировки. \n - Файл: `store.py` (строки 15–52).\n\n9. **WorkerSupervisor** \n - Наблюдатель за рабочими процессами. \n - Файл: `supervisor.py` (строки 10–59).\n\nСвязи внутри конструктора RuntimeManager включают инициализацию конфигурации, регистрацию сервисов и добавление конфигурационных файлов. \nФайл: `runtime.py`, строки 32–127.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 178 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 33, + "C3_ENTRYPOINTS": 16, + "C2_DEPENDENCY_GRAPH": 67, + "C1_SYMBOL_CATALOG": 36, + "C0_SOURCE_CHUNKS": 24 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 9368 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Какие компоненты участвуют в RuntimeManager?", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 12, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Компоненты, участвующие в RuntimeManager:\n\n1. **ControlPlaneService** \n - Регистрирует каналы управления (_register_channel_), запускается асинхронно (_start_async), останавливается (_stop_, _stop_async_). \n - Файлы: `service.py` (строки 14–52).\n\n2. **HttpControlAppFactory** \n - Фабрика для" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 178, + "pre_evidence_gate": 1, + "llm": 9368, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json similarity index 95% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json index 2a5103d..60170a3 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Что делает функция create_runtime?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Функция `create_runtime` инициализирует объект `RuntimeManager`, загружает конфигурацию из указанного файла (если путь задан), регистрирует HTTP-контроллер для управления состоянием приложения и регистрирует переданный модуль (`ApplicationModule`) в системе.\n\nКонкретно:\n1. Функция создаёт экземпляр `RuntimeManager`.\n2. Если указан путь к файлу конфигурации, файл загружается и добавляется в систему конфигурирования.\n3. При включении опции HTTP-контроллера создаётся и регистрируется соответствующий канал управления через класс `HttpControlChannel`.\n4. Переданный аргумент-модуль регистрируется в системе.\n\nЗависимости и вызовы внутри функции:\n- Загрузка конфигурации через чтение файла и его парсинг (используются библиотеки JSON и YAML).\n- Регистрация модуля в системе конфигурирования через метод `register_module`.", + "llm_answer": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если указан путь к конфигурационному файлу (`config_path`), добавляет его в менеджер.\n- Если включено управление через HTTP (`enable_http_control`), регистрирует HTTP-канал управления в плоскости контроля.\n- Регистрирует модуль приложения в менеджере времени выполнения.\n- Возвращает настроенный объект `RuntimeManager`.\n\nВходные параметры:\n- `module`: экземпляр `ApplicationModule`.\n- `config_path`: опциональный путь к конфигурационному файлу.\n- `enable_http_control`: флаг включения HTTP-контроля.\n- `control_host`, `control_port`, `control_timeout`: параметры подключения для HTTP-канала управления.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1338,36 +1338,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1395,6 +1375,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1418,6 +1405,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2591,11 +2612,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 34, - "C0_SOURCE_CHUNKS": 12, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 42, - "C3_ENTRYPOINTS": 10 + "C1_SYMBOL_CATALOG": 49, + "C0_SOURCE_CHUNKS": 24, + "C4_SEMANTIC_ROLES": 19, + "C2_DEPENDENCY_GRAPH": 49, + "C3_ENTRYPOINTS": 17 } } }, @@ -2611,6 +2632,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2678,12 +2702,41 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 113, - "pre_evidence_gate": 0, - "llm": 1394 + "router": 1, + "retrieval": 161, + "pre_evidence_gate": 1, + "llm": 4445, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -3789,7 +3842,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -3802,7 +3855,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 113 + "retrieval": 161 }, "output": { "rag_count": 33, @@ -3861,11 +3914,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 34, - "C0_SOURCE_CHUNKS": 12, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 42, - "C3_ENTRYPOINTS": 10 + "C1_SYMBOL_CATALOG": 49, + "C0_SOURCE_CHUNKS": 24, + "C4_SEMANTIC_ROLES": 19, + "C2_DEPENDENCY_GRAPH": 49, + "C3_ENTRYPOINTS": 17 } } }, @@ -3873,36 +3926,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 33 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1394 + "llm": 4445 }, "output": { "prompt_name": "code_qa_explain_answer", - "answer_preview": "Функция `create_runtime` инициализирует объект `RuntimeManager`, загружает конфигурацию из указанного файла (если путь задан), регистрирует HTTP-контроллер для управления состоянием приложения и регистрирует переданный модуль (`ApplicationModule`) в системе.\n\nКонкретно:\n1. Функция создаёт экземпляр " + "answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md new file mode 100644 index 0000000..e7b0f13 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md @@ -0,0 +1,305 @@ +# plba-v2-explain-create-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Что делает функция create_runtime? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если указан путь к конфигурационному файлу (`config_path`), добавляет его в менеджер.\n- Если включено управление через HTTP (`enable_http_control`), регистрирует HTTP-канал управления в плоскости контроля.\n- Регистрирует модуль приложения в менеджере времени выполнения.\n- Возвращает настроенный объект `RuntimeManager`.\n\nВходные параметры:\n- `module`: экземпляр `ApplicationModule`.\n- `config_path`: опциональный путь к конфигурационному файлу.\n- `enable_http_control`: флаг включения HTTP-контроля.\n- `control_host`, `control_port`, `control_timeout`: параметры подключения для HTTP-канала управления.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "create_runtime" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 161 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "create_runtime", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 49, + "C0_SOURCE_CHUNKS": 24, + "C4_SEMANTIC_ROLES": 19, + "C2_DEPENDENCY_GRAPH": 49, + "C3_ENTRYPOINTS": 17 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4445 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Что делает функция create_runtime?", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в модуле `src/plba/bootstrap.py`. Она создаёт и настраивает экземпляр `RuntimeManager`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP-канал управления.\n\nОсновные действия функции:\n- Инициализирует объект `RuntimeManager`.\n- Если" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 161, + "pre_evidence_gate": 1, + "llm": 4445, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json index 03b9151..c4a2606 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-local-http-channel", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` в файле `http_channel.py` реализует канал управления для HTTP-приложения. В конструкторе (`__init__`) инициализируются атрибуты:\n\n- `_timeout`: таймаут для канала.\n- `_runner`: экземпляр `UvicornThreadRunner`, управляющий запуском uvicorn-сервера.\n- `_factory`: фабрика приложений `HttpControlAppFactory`.\n- `_actions`: набор действий (контролируемых операций).\n\nМетод `start` запускает сервер с приложением, созданным фабрикой, и ассоциирует действия с каналом. Метод `stop` останавливает сервер. Класс использует асинхронный подход через аннотации `async`.", + "llm_answer": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фабрику и передавая обработчики здоровья и действий. \nМетоды _health_response и _action_response отвечают за обработку запросов к здоровью сервиса и выполнение действий соответственно. \nСтруктура класса ориентирована на создание отдельного HTTP-канала для управления приложением через HTTP-запросы.", "answer_mode": "answered", "path_scope": [ "src/app_runtime/control/http_channel.py" @@ -1458,9 +1458,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 23, - "C0_SOURCE_CHUNKS": 11, - "C2_DEPENDENCY_GRAPH": 13 + "C1_SYMBOL_CATALOG": 29, + "C0_SOURCE_CHUNKS": 14, + "C2_DEPENDENCY_GRAPH": 16 } } }, @@ -1474,6 +1474,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -1529,12 +1532,43 @@ "failure_reasons": [], "evidence_count": 13 }, + "evidence_gate_input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 47, - "pre_evidence_gate": 0, - "llm": 1155 + "router": 1, + "retrieval": 61, + "pre_evidence_gate": 1, + "llm": 3038, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -2043,7 +2077,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -2056,7 +2090,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 47 + "retrieval": 61 }, "output": { "rag_count": 13, @@ -2107,9 +2141,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 23, - "C0_SOURCE_CHUNKS": 11, - "C2_DEPENDENCY_GRAPH": 13 + "C1_SYMBOL_CATALOG": 29, + "C0_SOURCE_CHUNKS": 14, + "C2_DEPENDENCY_GRAPH": 16 } } }, @@ -2117,36 +2151,64 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 13 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1155 + "llm": 3038 }, "output": { "prompt_name": "code_qa_explain_local_answer", - "answer_preview": "Класс `HttpControlChannel` в файле `http_channel.py` реализует канал управления для HTTP-приложения. В конструкторе (`__init__`) инициализируются атрибуты:\n\n- `_timeout`: таймаут для канала.\n- `_runner`: экземпляр `UvicornThreadRunner`, управляющий запуском uvicorn-сервера.\n- `_factory`: фабрика при" + "answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md new file mode 100644 index 0000000..663d0e5 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md @@ -0,0 +1,285 @@ +# plba-v2-explain-local-http-channel + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 13, + "llm_answer": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фабрику и передавая обработчики здоровья и действий. \nМетоды _health_response и _action_response отвечают за обработку запросов к здоровью сервиса и выполнение действий соответственно. \nСтруктура класса ориентирована на создание отдельного HTTP-канала для управления приложением через HTTP-запросы.", + "answer_mode": "answered", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "symbol_candidates": [ + "HttpControlChannel" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 61 + }, + "output": { + "rag_count": 13, + "answer_path_rag_count": 13, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlChannel", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C2_DEPENDENCY_GRAPH": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 12, + "C2_DEPENDENCY_GRAPH": 4 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 29, + "C0_SOURCE_CHUNKS": 14, + "C2_DEPENDENCY_GRAPH": 16 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 13 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3038 + }, + "output": { + "prompt_name": "code_qa_explain_local_answer", + "answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN_LOCAL", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", + "sub_intent": "EXPLAIN_LOCAL", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 13 + }, + "evidence_gate_input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel в файле http_channel.py наследует ControlChannel и реализует HTTP-канал управления. \nОн имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner (используя Uvicorn для запуска сервера) и factory для создания FastAPI-приложения. \nМетод start запускает с" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 61, + "pre_evidence_gate": 1, + "llm": 3038, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json new file mode 100644 index 0000000..b3254ea --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json @@ -0,0 +1,632 @@ +{ + "case_id": "plba-v2-explain-nonexistent-symbol", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "runner": "agent_runtime", + "mode": "full_chain", + "query": "Объясни класс RuntimeFactoryManager", + "actual": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 0, + "llm_answer": "Сущность RuntimeFactoryManager не найдена в доступном коде.", + "answer_mode": "not_found", + "path_scope": [], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "passed": true, + "mismatches": [], + "details": { + "query": "Объясни класс RuntimeFactoryManager", + "router_result": { + "schema_version": "1.1", + "intent": "CODE_QA", + "retrieval_profile": "code", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "query_plan": { + "raw": "Объясни класс RuntimeFactoryManager", + "normalized": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "negations": [], + "expansions": [ + "RuntimeFactoryManager" + ], + "keyword_hints": [ + "RuntimeFactoryManager" + ], + "path_hints": [], + "doc_scope_hints": [], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "symbol_kind_hint": "class", + "anchors": [ + { + "type": "SYMBOL", + "value": "RuntimeFactoryManager", + "source": "user_text", + "subtype": null, + "span": { + "start": 14, + "end": 35 + }, + "confidence": 0.88 + }, + { + "type": "KEY_TERM", + "value": "класс", + "source": "user_text", + "subtype": null, + "span": { + "start": 8, + "end": 13 + }, + "confidence": 0.9 + } + ] + }, + "retrieval_spec": { + "domains": [ + "CODE" + ], + "layer_queries": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "top_k": 8 + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "top_k": 8 + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "top_k": 8 + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "top_k": 6 + }, + { + "layer_id": "C3_ENTRYPOINTS", + "top_k": 6 + } + ], + "filters": { + "test_policy": "EXCLUDE", + "path_scope": [], + "language": [ + "python" + ] + }, + "rerank_profile": "code" + }, + "retrieval_constraints": { + "include_globs": [ + "src/**" + ], + "exclude_globs": [ + "tests/**", + "**/test_*.py", + "**/*_test.py" + ], + "prefer_globs": [], + "test_file_globs": [], + "test_symbol_patterns": [], + "max_candidates": 20, + "fuzzy_symbol_search": { + "enabled": true, + "max_distance": 2, + "top_k": 5 + } + }, + "symbol_resolution": { + "status": "not_found", + "resolved_symbol": null, + "alternatives": [], + "confidence": 0.0 + }, + "evidence_policy": { + "require_def": true, + "require_flow": true, + "require_spec": false, + "allow_answer_without_evidence": false + } + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "keyword_hints": [ + "RuntimeFactoryManager" + ], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_spec": { + "domains": [ + "CODE" + ], + "layer_queries": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "top_k": 8 + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "top_k": 8 + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "top_k": 8 + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "top_k": 6 + }, + { + "layer_id": "C3_ENTRYPOINTS", + "top_k": 6 + } + ], + "filters": { + "test_policy": "EXCLUDE", + "path_scope": [], + "language": [ + "python" + ] + }, + "rerank_profile": "code" + }, + "retrieval_constraints": { + "include_globs": [ + "src/**" + ], + "exclude_globs": [ + "tests/**", + "**/test_*.py", + "**/*_test.py" + ], + "prefer_globs": [], + "test_file_globs": [], + "test_symbol_patterns": [], + "max_candidates": 20, + "fuzzy_symbol_search": { + "enabled": true, + "max_distance": 2, + "top_k": 5 + } + }, + "query_plan": { + "raw": "Объясни класс RuntimeFactoryManager", + "normalized": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "negations": [], + "expansions": [ + "RuntimeFactoryManager" + ], + "keyword_hints": [ + "RuntimeFactoryManager" + ], + "path_hints": [], + "doc_scope_hints": [], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "symbol_kind_hint": "class", + "anchors": [ + { + "type": "SYMBOL", + "value": "RuntimeFactoryManager", + "source": "user_text", + "subtype": null, + "span": { + "start": 14, + "end": 35 + }, + "confidence": 0.88 + }, + { + "type": "KEY_TERM", + "value": "класс", + "source": "user_text", + "subtype": null, + "span": { + "start": 8, + "end": 13 + }, + "confidence": 0.9 + } + ] + } + }, + "retrieval_result": { + "target_symbol_candidates": [], + "resolved_symbol": null, + "symbol_resolution_status": "not_found", + "file_candidates": [], + "code_chunks": [], + "relations": [], + "entrypoints": [], + "test_candidates": [], + "layer_outcomes": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 0, + "empty": true, + "fallback_used": false + } + ], + "missing_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "raw_rows": [], + "retrieval_report": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 55, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 24, + "C2_DEPENDENCY_GRAPH": 59, + "C3_ENTRYPOINTS": 18 + } + } + }, + "diagnostics": { + "intent_correct": null, + "target_found": false, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": false, + "answer_mode": "insufficient", + "resolved_target": null, + "answer_policy_branch": "explain_not_found", + "decision_reason": "symbol_resolution_not_found", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 0, + "empty": true, + "fallback_used": false + } + ], + "empty_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "evidence_gate_decision": { + "sufficient": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "evidence_count": 0 + }, + "evidence_gate_input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "insufficient_evidence" + ], + "timings_ms": { + "router": 2, + "retrieval": 184, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } + }, + "rag_rows": [], + "validation": { + "passed": true, + "action": "return", + "reasons": [] + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 184 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 55, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 24, + "C2_DEPENDENCY_GRAPH": 59, + "C3_ENTRYPOINTS": 18 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met).", + "evidence_count": 0 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "symbol_resolution_not_found", + "answer_policy_branch": "explain_not_found" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + } + ] + } +} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md similarity index 54% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md index f4b5c22..7dc52a4 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md @@ -1,12 +1,12 @@ -# plba-v2-explain-trace-service +# plba-v2-explain-nonexistent-symbol -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml - runner: agent_runtime - mode: full_chain - passed: True ## Query -Объясни как работает класс TraceService +Объясни класс RuntimeFactoryManager ## Actual { @@ -14,12 +14,12 @@ "sub_intent": "EXPLAIN", "graph_id": "CodeQAGraph", "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `TraceService` определяется в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory`.\n\nЕго основные обязанности:\n- Инициализация при создании через параметры `transport` и `store`, с возможностью использования стандартных реализаций (`NoOpTraceTransport` и `TraceContextStore`).\n- Метод `create_context` создаёт новый контекст трассировки с заданными параметрами и записывает его в хранилище.\n- Методы `current_trace_id` и `step` предоставляют доступ к текущему идентификатору трассы и выполняют дополнительные действия.\n\nДетали реализации зависят от конкретных методов, таких как инициализация транспорта и контекста, а также запись записей трассировки в хранилище.", - "answer_mode": "answered", + "rag_count": 0, + "llm_answer": "Сущность RuntimeFactoryManager не найдена в доступном коде.", + "answer_mode": "not_found", "path_scope": [], "symbol_candidates": [ - "TraceService" + "RuntimeFactoryManager" ], "layers": [ "C1_SYMBOL_CATALOG", @@ -36,7 +36,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 2 }, "output": { "intent": "CODE_QA", @@ -49,13 +49,13 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 147 + "retrieval": 184 }, "output": { "rag_count": 33, - "answer_path_rag_count": 33, - "resolved_symbol_status": "resolved", - "resolved_symbol": "TraceService", + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, "requested_layers": [ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", @@ -108,48 +108,67 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 64, - "C0_SOURCE_CHUNKS": 15, - "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 43, - "C3_ENTRYPOINTS": 10 + "C1_SYMBOL_CATALOG": 55, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 24, + "C2_DEPENDENCY_GRAPH": 59, + "C3_ENTRYPOINTS": 18 } } }, { "step": "pre_evidence_gate", - "status": "passed", + "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] }, "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" + "passed": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met).", + "evidence_count": 0 } }, { "step": "llm", - "status": "completed", + "status": "skipped", "timings_ms": { - "llm": 1347 + "llm": 1 }, "output": { - "prompt_name": "code_qa_explain_answer", - "answer_preview": "Класс `TraceService` определяется в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory`.\n\nЕго основные обязанности:\n- Инициализация при создании через параметры `transport` и `store`, с возможностью использования стандартных реализаций (`NoOpTraceTransport` и `TraceCont" + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "symbol_resolution_not_found", + "answer_policy_branch": "explain_not_found" } }, { "step": "post_evidence_gate", - "status": "passed", + "status": "skipped", "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null }, "output": { - "passed": true, - "reasons": [], - "repair_used": false + "reason": "no_draft_answer" } } ] @@ -157,7 +176,7 @@ ## Diagnostics { "intent_correct": null, - "target_found": true, + "target_found": false, "layers_used": [ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", @@ -165,8 +184,11 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "retrieval_sufficient": true, - "answer_mode": "normal", + "retrieval_sufficient": false, + "answer_mode": "insufficient", + "resolved_target": null, + "answer_policy_branch": "explain_not_found", + "decision_reason": "symbol_resolution_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -181,11 +203,11 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "resolved" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс TraceService", + "query": "Объясни класс RuntimeFactoryManager", "sub_intent": "EXPLAIN", "path_scope": [], "requested_layers": [ @@ -199,47 +221,79 @@ "per_layer_outcome": [ { "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false } ], - "empty_layers": [], + "empty_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 + "sufficient": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "evidence_count": 0 }, - "failure_reasons": [], + "evidence_gate_input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "insufficient_evidence" + ], "timings_ms": { - "router": 0, - "retrieval": 147, - "pre_evidence_gate": 0, - "llm": 1347 + "router": 2, + "retrieval": 184, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json similarity index 96% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json index 1483a68..e95197d 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Объясни как работает класс RuntimeManager", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Класс `RuntimeManager` находится в файле `src/app_runtime/core/runtime.py`. Конкретной реализации инициализации или подробного описания методов в предоставленном контексте не видно. Однако исходя из имеющихся признаков:\n\n1. Класс имеет ответственность за управление состоянием и конфигурацией runtime-системы, судя по названиям атрибутов и методов в окружении (`configuration`, `add_config_file`).\n2. Вероятно, он участвует в оркестрации различных компонентов системы через свои методы и атрибуты, хотя детальной информации об этих методах и атрибутах нет.\n\nТаким образом, класс `RuntimeManager` играет ключевую управляющую роль в системе, вероятно, интегрируя и координируя другие компоненты и модули.", + "llm_answer": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `RuntimeManager.configuration`\n- `RuntimeManager.add_config_file`\n\nСвязи и вызовы других сущностей не указаны явно в данном контексте, но известно, что `RuntimeManager` используется в службах контроля (`ControlPlaneService`) и взаимодействует с ними через методы старта, стопа и получения снимков состояния.\n\nДополнительные детали о взаимодействии с другими компонентами отсутствуют в представленном контексте.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1521,36 +1521,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1578,6 +1558,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1601,6 +1588,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2870,11 +2891,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 76, - "C0_SOURCE_CHUNKS": 20, + "C1_SYMBOL_CATALOG": 68, + "C0_SOURCE_CHUNKS": 25, "C4_SEMANTIC_ROLES": 22, - "C2_DEPENDENCY_GRAPH": 62, - "C3_ENTRYPOINTS": 12 + "C2_DEPENDENCY_GRAPH": 61, + "C3_ENTRYPOINTS": 17 } } }, @@ -2890,6 +2911,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2957,12 +2981,41 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 194, - "pre_evidence_gate": 0, - "llm": 1244 + "router": 1, + "retrieval": 195, + "pre_evidence_gate": 1, + "llm": 3442, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -4164,7 +4217,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -4177,7 +4230,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 194 + "retrieval": 195 }, "output": { "rag_count": 33, @@ -4236,11 +4289,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 76, - "C0_SOURCE_CHUNKS": 20, + "C1_SYMBOL_CATALOG": 68, + "C0_SOURCE_CHUNKS": 25, "C4_SEMANTIC_ROLES": 22, - "C2_DEPENDENCY_GRAPH": 62, - "C3_ENTRYPOINTS": 12 + "C2_DEPENDENCY_GRAPH": 61, + "C3_ENTRYPOINTS": 17 } } }, @@ -4248,36 +4301,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 33 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1244 + "llm": 3442 }, "output": { "prompt_name": "code_qa_explain_answer", - "answer_preview": "Класс `RuntimeManager` находится в файле `src/app_runtime/core/runtime.py`. Конкретной реализации инициализации или подробного описания методов в предоставленном контексте не видно. Однако исходя из имеющихся признаков:\n\n1. Класс имеет ответственность за управление состоянием и конфигурацией runtime" + "answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md new file mode 100644 index 0000000..541464f --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md @@ -0,0 +1,305 @@ +# plba-v2-explain-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Объясни как работает класс RuntimeManager + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `RuntimeManager.configuration`\n- `RuntimeManager.add_config_file`\n\nСвязи и вызовы других сущностей не указаны явно в данном контексте, но известно, что `RuntimeManager` используется в службах контроля (`ControlPlaneService`) и взаимодействует с ними через методы старта, стопа и получения снимков состояния.\n\nДополнительные детали о взаимодействии с другими компонентами отсутствуют в представленном контексте.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 195 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 68, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 22, + "C2_DEPENDENCY_GRAPH": 61, + "C3_ENTRYPOINTS": 17 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3442 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни как работает класс RuntimeManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow.\n\nКонструктор `RuntimeManager.__init__` инициализирует объект и вызывает:\n- `Runtim" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 195, + "pre_evidence_gate": 1, + "llm": 3442, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json similarity index 96% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json index 4ea380a..8463d28 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Объясни как работает класс TraceService", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Класс `TraceService` определяется в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory`.\n\nЕго основные обязанности:\n- Инициализация при создании через параметры `transport` и `store`, с возможностью использования стандартных реализаций (`NoOpTraceTransport` и `TraceContextStore`).\n- Метод `create_context` создаёт новый контекст трассировки с заданными параметрами и записывает его в хранилище.\n- Методы `current_trace_id` и `step` предоставляют доступ к текущему идентификатору трассы и выполняют дополнительные действия.\n\nДетали реализации зависят от конкретных методов, таких как инициализация транспорта и контекста, а также запись записей трассировки в хранилище.", + "llm_answer": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если транспорт или хранилище не указаны, используются реализации по умолчанию: `NoOpTraceTransport()` и `TraceContextStore()`.\n \n- **Метод `create_context`**: создаёт новый контекст трассировки, принимая параметры `alias`, `parent_id`, `kind` и `attrs`. В нём создаётся запись контекста трассировки с уникальным идентификатором, текущим временем и переданными параметрами, затем эта запись сохраняется в хранилище.\n\nТакже определены методы `open_context`, `close_context`, `current_trace_id`, но их реализация не приведена в контексте.\n\nОсторожный вывод: `TraceService` используется для управления контекстами трассировки приложения, позволяя создавать, открывать и управлять записями трассировок. Он играет ключевую роль в инфраструктуре отслеживания и логирования внутри приложения. \n\nФакты основаны на видимом фрагменте кода.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1524,36 +1524,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1581,6 +1561,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1604,6 +1591,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2873,11 +2894,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 64, - "C0_SOURCE_CHUNKS": 15, - "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 43, - "C3_ENTRYPOINTS": 10 + "C1_SYMBOL_CATALOG": 50, + "C0_SOURCE_CHUNKS": 18, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 50, + "C3_ENTRYPOINTS": 17 } } }, @@ -2893,6 +2914,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2960,12 +2984,41 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 147, - "pre_evidence_gate": 0, - "llm": 1347 + "router": 2, + "retrieval": 156, + "pre_evidence_gate": 1, + "llm": 5609, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -4167,7 +4220,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 2 }, "output": { "intent": "CODE_QA", @@ -4180,7 +4233,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 147 + "retrieval": 156 }, "output": { "rag_count": 33, @@ -4239,11 +4292,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 64, - "C0_SOURCE_CHUNKS": 15, - "C4_SEMANTIC_ROLES": 14, - "C2_DEPENDENCY_GRAPH": 43, - "C3_ENTRYPOINTS": 10 + "C1_SYMBOL_CATALOG": 50, + "C0_SOURCE_CHUNKS": 18, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 50, + "C3_ENTRYPOINTS": 17 } } }, @@ -4251,36 +4304,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 33 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1347 + "llm": 5609 }, "output": { "prompt_name": "code_qa_explain_answer", - "answer_preview": "Класс `TraceService` определяется в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory`.\n\nЕго основные обязанности:\n- Инициализация при создании через параметры `transport` и `store`, с возможностью использования стандартных реализаций (`NoOpTraceTransport` и `TraceCont" + "answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md new file mode 100644 index 0000000..baf3eb0 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md @@ -0,0 +1,305 @@ +# plba-v2-explain-trace-service + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Объясни как работает класс TraceService + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если транспорт или хранилище не указаны, используются реализации по умолчанию: `NoOpTraceTransport()` и `TraceContextStore()`.\n \n- **Метод `create_context`**: создаёт новый контекст трассировки, принимая параметры `alias`, `parent_id`, `kind` и `attrs`. В нём создаётся запись контекста трассировки с уникальным идентификатором, текущим временем и переданными параметрами, затем эта запись сохраняется в хранилище.\n\nТакже определены методы `open_context`, `close_context`, `current_trace_id`, но их реализация не приведена в контексте.\n\nОсторожный вывод: `TraceService` используется для управления контекстами трассировки приложения, позволяя создавать, открывать и управлять записями трассировок. Он играет ключевую роль в инфраструктуре отслеживания и логирования внутри приложения. \n\nФакты основаны на видимом фрагменте кода.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "TraceService" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 156 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "TraceService", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 50, + "C0_SOURCE_CHUNKS": 18, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 50, + "C3_ENTRYPOINTS": 17 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 5609 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни как работает класс TraceService", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследуется от `TraceContextFactory`.\n\nОсновные компоненты:\n\n- **Конструктор (`__init__`)**: принимает параметры `transport` и `store`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если тра" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 2, + "retrieval": 156, + "pre_evidence_gate": 1, + "llm": 5609, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json similarity index 87% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json index bab51a9..03ca84f 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-entrypoints-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Найди точки входа HTTP control plane", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 9, - "llm_answer": "Confirmed Entrypoints:\n1. src/app_runtime/control/http_app.py:app.post (lines 38-42)\n2. src/app_runtime/control/http_app.py:app.get (lines 31-34)\n3. src/app_runtime/control/http_app.py:app.get (lines 38-42)", + "llm_answer": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n\nКандидаты на входы не требуются, так как все маршруты уже подтверждены.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -135,13 +135,9 @@ } }, "symbol_resolution": { - "status": "pending", + "status": "not_found", "resolved_symbol": null, - "alternatives": [ - "HTTP", - "control", - "plane" - ], + "alternatives": [], "confidence": 0.0 }, "evidence_policy": { @@ -524,36 +520,16 @@ ], "relations": [], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -581,6 +557,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -604,6 +587,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -922,18 +939,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -941,9 +960,16 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 11, - "C0_SOURCE_CHUNKS": 21 - } + "C3_ENTRYPOINTS": 16, + "C0_SOURCE_CHUNKS": 12 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Найди точки входа HTTP control plane", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, "diagnostics": { @@ -955,6 +981,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -966,7 +995,7 @@ "C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -998,8 +1027,42 @@ "failure_reasons": [], "evidence_count": 9 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 38, + "pre_evidence_gate": 1, + "llm": 2451, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -1298,6 +1361,139 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 38 + }, + "output": { + "rag_count": 9, + "answer_path_rag_count": 9, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 16, + "C0_SOURCE_CHUNKS": 12 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Найди точки входа HTTP control plane", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 9 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 2451 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md new file mode 100644 index 0000000..3143dd5 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md @@ -0,0 +1,262 @@ +# plba-v2-find-entrypoints-control-plane + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Найди точки входа HTTP control plane + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 9, + "llm_answer": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n\nКандидаты на входы не требуются, так как все маршруты уже подтверждены.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "HTTP", + "control", + "plane" + ], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 38 + }, + "output": { + "rag_count": 9, + "answer_path_rag_count": 9, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 16, + "C0_SOURCE_CHUNKS": 12 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Найди точки входа HTTP control plane", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 9 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 2451 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Найди точки входа HTTP control plane", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 6, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 9 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n- GET /health, объявлен в src/app_runtime/control/http_app.py, строки 31-34, обработчик health\n- GET /actions/{action}, объявлен в src/app_runtime/control/http_app.py, строки 38-42, обработчик action\n- POST /actions/{action}, объявлен в src/app_runtime/control/http_app.p" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 38, + "pre_evidence_gate": 1, + "llm": 2451, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json similarity index 79% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json index 0c1fe54..29d5b1e 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-entrypoints-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где health endpoint?", @@ -9,8 +9,8 @@ "sub_intent": "FIND_ENTRYPOINTS", "graph_id": "CodeQAGraph", "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Конкретных health-endpoint'ов, объявленных как routes, не найдено.\n\nОднако, исходя из предоставленного кода:\n- В `http_app.py` есть две явные декларации маршрутов с использованием декоратора `app.get`, но neither из них явно помечен как health-check (метод и путь не указаны).\n- Есть декларация `app.post`, но она также не маркируется как health-related.\n\nТаким образом, хотя health-checking инфраструктура существует (через класс `HealthRegistry`), конкретный health-endpoint не обнаружен среди зарегистрированных маршрутов.", + "rag_count": 10, + "llm_answer": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -22,10 +22,8 @@ "C0_SOURCE_CHUNKS" ] }, - "passed": false, - "mismatches": [ - "llm: expected answer to contain 'GET /health'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Где health endpoint?", "router_result": { @@ -488,28 +486,22 @@ "last_modified": null, "staleness_score": null } - } - ], - "relations": [], - "entrypoints": [ + }, { + "layer": "C0_SOURCE_CHUNKS", "path": "src/app_runtime/control/http_app.py", - "title": "app.post", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "start_line": 15, + "end_line": 53, "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", "repo_id": "plba", + "artifact_type": null, "section": null, "doc_id": null, "doc_version": null, @@ -518,10 +510,20 @@ "last_modified": null, "staleness_score": null } - }, + } + ], + "relations": [], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -549,6 +551,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -572,6 +581,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -584,7 +627,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -881,6 +924,36 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "retrieval_report": { @@ -890,18 +963,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -909,9 +984,16 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 28, - "C0_SOURCE_CHUNKS": 18 - } + "C3_ENTRYPOINTS": 34, + "C0_SOURCE_CHUNKS": 15 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, "diagnostics": { @@ -923,6 +1005,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -955,7 +1040,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -964,14 +1049,43 @@ "evidence_gate_decision": { "sufficient": true, "failure_reasons": [], - "evidence_count": 9 + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 46, - "pre_evidence_gate": 0, - "llm": 1055 + "router": 1, + "retrieval": 56, + "pre_evidence_gate": 1, + "llm": 1462, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -1265,6 +1379,36 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "validation": { @@ -1277,7 +1421,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -1290,11 +1434,11 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 46 + "retrieval": 56 }, "output": { - "rag_count": 9, - "answer_path_rag_count": 9, + "rag_count": 10, + "answer_path_rag_count": 10, "resolved_symbol_status": "not_found", "resolved_symbol": null, "requested_layers": [ @@ -1309,18 +1453,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -1328,45 +1474,78 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 28, - "C0_SOURCE_CHUNKS": 18 - } + "C3_ENTRYPOINTS": 34, + "C0_SOURCE_CHUNKS": 15 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, { "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 10 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1055 + "llm": 1462 }, "output": { "prompt_name": "code_qa_find_entrypoints_answer", - "answer_preview": "Конкретных health-endpoint'ов, объявленных как routes, не найдено.\n\nОднако, исходя из предоставленного кода:\n- В `http_app.py` есть две явные декларации маршрутов с использованием декоратора `app.get`, но neither из них явно помечен как health-check (метод и путь не указаны).\n- Есть декларация `app." + "answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md new file mode 100644 index 0000000..4b489c1 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md @@ -0,0 +1,261 @@ +# plba-v2-find-entrypoints-health-endpoint + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где health endpoint? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 10, + "llm_answer": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "health", + "endpoint" + ], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 56 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 34, + "C0_SOURCE_CHUNKS": 15 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1462 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где health endpoint?", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 7, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 56, + "pre_evidence_gate": 1, + "llm": 1462, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json similarity index 96% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json index a33cda0..000671e 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для create_runtime?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "Прямых тестов для `create_runtime` не обнаружено. Ближайший тест расположен в файле `tests/test_runtime.py`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод `create_runtime`. Косвенное покрытие отсутствует.", + "llm_answer": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1901,9 +1901,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 33, - "C2_DEPENDENCY_GRAPH": 38, - "C0_SOURCE_CHUNKS": 13 + "C1_SYMBOL_CATALOG": 24, + "C2_DEPENDENCY_GRAPH": 29, + "C0_SOURCE_CHUNKS": 10 } } }, @@ -1917,6 +1917,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -1968,12 +1971,41 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`." + } + }, "failure_reasons": [], "timings_ms": { "router": 1, - "retrieval": 85, - "pre_evidence_gate": 0, - "llm": 611 + "retrieval": 64, + "pre_evidence_gate": 1, + "llm": 1663, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -2769,7 +2801,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 85 + "retrieval": 64 }, "output": { "rag_count": 24, @@ -2814,9 +2846,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 33, - "C2_DEPENDENCY_GRAPH": 38, - "C0_SOURCE_CHUNKS": 13 + "C1_SYMBOL_CATALOG": 24, + "C2_DEPENDENCY_GRAPH": 29, + "C0_SOURCE_CHUNKS": 10 } } }, @@ -2824,36 +2856,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 24 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 611 + "llm": 1663 }, "output": { "prompt_name": "code_qa_find_tests_answer", - "answer_preview": "Прямых тестов для `create_runtime` не обнаружено. Ближайший тест расположен в файле `tests/test_runtime.py`, но он проверяет экспорт публичных контрактов пакета PLBA, а не непосредственно сам метод `create_runtime`. Косвенное покрытие отсутствует." + "answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`." } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md new file mode 100644 index 0000000..06dbc0f --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md @@ -0,0 +1,269 @@ +# plba-v2-find-tests-create-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для create_runtime? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "create_runtime" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 64 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "create_runtime", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 24, + "C2_DEPENDENCY_GRAPH": 29, + "C0_SOURCE_CHUNKS": 10 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1663 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для create_runtime?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая `create_runtime`." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 64, + "pre_evidence_gate": 1, + "llm": 1663, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json similarity index 97% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json index fe9f75a..763215d 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для RuntimeManager?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`. Эти тесты проверяют инициализацию и поведение объекта `RuntimeManager`.\n\nКосвенных тестов, явно связанных с `RuntimeManager`, больше нигде не обнаружено.", + "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -2192,9 +2192,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 58, - "C2_DEPENDENCY_GRAPH": 58, - "C0_SOURCE_CHUNKS": 24 + "C1_SYMBOL_CATALOG": 48, + "C2_DEPENDENCY_GRAPH": 59, + "C0_SOURCE_CHUNKS": 21 } } }, @@ -2208,6 +2208,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2259,12 +2262,41 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + }, "failure_reasons": [], "timings_ms": { "router": 1, - "retrieval": 141, - "pre_evidence_gate": 0, - "llm": 584 + "retrieval": 129, + "pre_evidence_gate": 1, + "llm": 1551, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -3156,7 +3188,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 141 + "retrieval": 129 }, "output": { "rag_count": 24, @@ -3201,9 +3233,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 58, - "C2_DEPENDENCY_GRAPH": 58, - "C0_SOURCE_CHUNKS": 24 + "C1_SYMBOL_CATALOG": 48, + "C2_DEPENDENCY_GRAPH": 59, + "C0_SOURCE_CHUNKS": 21 } } }, @@ -3211,36 +3243,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 24 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 584 + "llm": 1551 }, "output": { "prompt_name": "code_qa_find_tests_answer", - "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`. Эти тесты проверяют инициализацию и поведение объекта `RuntimeManager`.\n\nКосвенных тестов, явно связанных с `RuntimeManager`, больше нигде не обнаружено." + "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md new file mode 100644 index 0000000..a4e89a9 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md @@ -0,0 +1,269 @@ +# plba-v2-find-tests-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для RuntimeManager? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 129 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 48, + "C2_DEPENDENCY_GRAPH": 59, + "C0_SOURCE_CHUNKS": 21 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1551 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для RuntimeManager?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 129, + "pre_evidence_gate": 1, + "llm": 1551, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json similarity index 97% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json index 353a6c0..38f1f7a 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для TraceService?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "Прямые тесты для `TraceService` обнаружены в файле `tests/test_runtime.py`. Проверяются следующие аспекты:\n\n- `test_trace_service_allows_messages_without_status`: проверка обработки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверка записи контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверка поддержки различных уровней логирования (DEBUG, WARNING, ERROR).", + "llm_answer": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверяет поддержку уровней debug, warning и error.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -2193,9 +2193,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 36, - "C2_DEPENDENCY_GRAPH": 31, - "C0_SOURCE_CHUNKS": 12 + "C1_SYMBOL_CATALOG": 41, + "C2_DEPENDENCY_GRAPH": 42, + "C0_SOURCE_CHUNKS": 35 } } }, @@ -2209,6 +2209,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2260,12 +2263,41 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 80, - "pre_evidence_gate": 0, - "llm": 820 + "router": 1, + "retrieval": 119, + "pre_evidence_gate": 1, + "llm": 2200, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -3144,7 +3176,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -3157,7 +3189,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 80 + "retrieval": 119 }, "output": { "rag_count": 24, @@ -3202,9 +3234,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 36, - "C2_DEPENDENCY_GRAPH": 31, - "C0_SOURCE_CHUNKS": 12 + "C1_SYMBOL_CATALOG": 41, + "C2_DEPENDENCY_GRAPH": 42, + "C0_SOURCE_CHUNKS": 35 } } }, @@ -3212,36 +3244,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 24 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 820 + "llm": 2200 }, "output": { "prompt_name": "code_qa_find_tests_answer", - "answer_preview": "Прямые тесты для `TraceService` обнаружены в файле `tests/test_runtime.py`. Проверяются следующие аспекты:\n\n- `test_trace_service_allows_messages_without_status`: проверка обработки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверка записи контекстов и сообщений.\n- " + "answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md new file mode 100644 index 0000000..fe688c2 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md @@ -0,0 +1,269 @@ +# plba-v2-find-tests-trace-service + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для TraceService? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверяет поддержку уровней debug, warning и error.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "TraceService" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 119 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "TraceService", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 41, + "C2_DEPENDENCY_GRAPH": 42, + "C0_SOURCE_CHUNKS": 35 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 2200 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для TraceService?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 119, + "pre_evidence_gate": 1, + "llm": 2200, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json similarity index 98% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json index 049066a..7815d88 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-workflow-runtime-factory-negative", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для WorkflowRuntimeFactory?", @@ -2086,9 +2086,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 27, - "C2_DEPENDENCY_GRAPH": 29, - "C0_SOURCE_CHUNKS": 17 + "C1_SYMBOL_CATALOG": 24, + "C2_DEPENDENCY_GRAPH": 36, + "C0_SOURCE_CHUNKS": 20 } } }, @@ -2102,6 +2102,9 @@ ], "retrieval_sufficient": false, "answer_mode": "degraded", + "resolved_target": "WorkflowRuntimeFactory", + "answer_policy_branch": "evidence_gate_short_circuit", + "decision_reason": "tests_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2155,13 +2158,36 @@ ], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "tests_not_found" ], "timings_ms": { - "router": 0, - "retrieval": 74, - "pre_evidence_gate": 0 + "router": 1, + "retrieval": 82, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -3010,7 +3036,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -3023,7 +3049,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 74 + "retrieval": 82 }, "output": { "rag_count": 24, @@ -3068,9 +3094,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 27, - "C2_DEPENDENCY_GRAPH": 29, - "C0_SOURCE_CHUNKS": 17 + "C1_SYMBOL_CATALOG": 24, + "C2_DEPENDENCY_GRAPH": 36, + "C0_SOURCE_CHUNKS": 20 } } }, @@ -3078,27 +3104,53 @@ "step": "pre_evidence_gate", "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": false, "failure_reasons": [ "tests_not_found" ], - "degraded_message": "Insufficient evidence for a confident answer. No test candidates found." + "degraded_message": "Insufficient evidence for a confident answer. No test candidates found.", + "evidence_count": 24 } }, { "step": "llm", "status": "skipped", + "timings_ms": { + "llm": 1 + }, "output": { "reason": "policy_short_circuit", - "answer_mode": "degraded" + "answer_mode": "degraded", + "decision_reason": "tests_not_found", + "answer_policy_branch": "evidence_gate_short_circuit" } }, { "step": "post_evidence_gate", "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, "output": { "reason": "no_draft_answer" } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md similarity index 69% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md index 4c62657..a87b0c0 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md @@ -1,6 +1,6 @@ # plba-v2-find-tests-workflow-runtime-factory-negative -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml - runner: agent_runtime - mode: full_chain - passed: True @@ -34,7 +34,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -47,7 +47,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 74 + "retrieval": 82 }, "output": { "rag_count": 24, @@ -92,9 +92,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 27, - "C2_DEPENDENCY_GRAPH": 29, - "C0_SOURCE_CHUNKS": 17 + "C1_SYMBOL_CATALOG": 24, + "C2_DEPENDENCY_GRAPH": 36, + "C0_SOURCE_CHUNKS": 20 } } }, @@ -102,27 +102,53 @@ "step": "pre_evidence_gate", "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": false, "failure_reasons": [ "tests_not_found" ], - "degraded_message": "Insufficient evidence for a confident answer. No test candidates found." + "degraded_message": "Insufficient evidence for a confident answer. No test candidates found.", + "evidence_count": 24 } }, { "step": "llm", "status": "skipped", + "timings_ms": { + "llm": 1 + }, "output": { "reason": "policy_short_circuit", - "answer_mode": "degraded" + "answer_mode": "degraded", + "decision_reason": "tests_not_found", + "answer_policy_branch": "evidence_gate_short_circuit" } }, { "step": "post_evidence_gate", "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, "output": { "reason": "no_draft_answer" } @@ -140,6 +166,9 @@ ], "retrieval_sufficient": false, "answer_mode": "degraded", + "resolved_target": "WorkflowRuntimeFactory", + "answer_policy_branch": "evidence_gate_short_circuit", + "decision_reason": "tests_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -193,13 +222,36 @@ ], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "tests_not_found" ], "timings_ms": { - "router": 0, - "retrieval": 74, - "pre_evidence_gate": 0 + "router": 1, + "retrieval": 82, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json similarity index 83% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json index d481c08..73dc7e5 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-nonexistent", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/app_runtime/core/missing_runtime.py", @@ -266,7 +266,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 10 + "C0_SOURCE_CHUNKS": 14 } } }, @@ -278,6 +278,9 @@ ], "retrieval_sufficient": false, "answer_mode": "insufficient", + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "answer_policy_branch": "open_file_not_found", + "decision_reason": "path_scope_empty", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -322,14 +325,39 @@ ], "evidence_count": 0 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "path_scope_empty", "layer_c0_empty" ], "timings_ms": { - "router": 0, - "retrieval": 10, - "pre_evidence_gate": 0 + "router": 1, + "retrieval": 15, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } }, "rag_rows": [], @@ -343,7 +371,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -356,7 +384,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 10 + "retrieval": 15 }, "output": { "rag_count": 0, @@ -396,7 +424,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 10 + "C0_SOURCE_CHUNKS": 14 } } }, @@ -404,7 +432,21 @@ "step": "pre_evidence_gate", "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] }, "output": { "passed": false, @@ -412,20 +454,34 @@ "path_scope_empty", "layer_c0_empty" ], - "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved." + "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved.", + "evidence_count": 0 } }, { "step": "llm", "status": "skipped", + "timings_ms": { + "llm": 1 + }, "output": { "reason": "policy_short_circuit", - "answer_mode": "not_found" + "answer_mode": "not_found", + "decision_reason": "path_scope_empty", + "answer_policy_branch": "open_file_not_found" } }, { "step": "post_evidence_gate", "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, "output": { "reason": "no_draft_answer" } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md similarity index 67% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md index 79babdc..8f60590 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md @@ -1,6 +1,6 @@ # plba-v2-open-file-nonexistent -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml - runner: agent_runtime - mode: full_chain - passed: True @@ -32,7 +32,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -45,7 +45,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 10 + "retrieval": 15 }, "output": { "rag_count": 0, @@ -85,7 +85,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 10 + "C0_SOURCE_CHUNKS": 14 } } }, @@ -93,7 +93,21 @@ "step": "pre_evidence_gate", "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] }, "output": { "passed": false, @@ -101,20 +115,34 @@ "path_scope_empty", "layer_c0_empty" ], - "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved." + "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved.", + "evidence_count": 0 } }, { "step": "llm", "status": "skipped", + "timings_ms": { + "llm": 1 + }, "output": { "reason": "policy_short_circuit", - "answer_mode": "not_found" + "answer_mode": "not_found", + "decision_reason": "path_scope_empty", + "answer_policy_branch": "open_file_not_found" } }, { "step": "post_evidence_gate", "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, "output": { "reason": "no_draft_answer" } @@ -130,6 +158,9 @@ ], "retrieval_sufficient": false, "answer_mode": "insufficient", + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "answer_policy_branch": "open_file_not_found", + "decision_reason": "path_scope_empty", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -174,14 +205,39 @@ ], "evidence_count": 0 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "path_scope_empty", "layer_c0_empty" ], "timings_ms": { - "router": 0, - "retrieval": 10, - "pre_evidence_gate": 0 + "router": 1, + "retrieval": 15, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json similarity index 69% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json index 6e26093..435f2a9 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-public-api", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/plba/__init__.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 1, - "llm_answer": "В файле src/plba/__init__.py видны следующие импорты и определения:\n\n- from plba.bootstrap import create_runtime\n- from plba.config import ConfigFileLoader, FileConfigProvider\n- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\n- from plba.contracts import ApplicationModule, ConfigProvider, HealthContributor, TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport, Worker, WorkerHealth, WorkerStatus\n- from plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\n- from plba.health import HealthRegistry\n- from plba.logging import LogManager\n- from plba.queue import InMemoryTaskQueue\n- from plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\n- from plba.workflow import StepResult, WorkflowContext, WorkflowDefinition, Workflo", + "llm_answer": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: несколько контрактов, таких как `ApplicationModule`, `ConfigProvider`, `Worker`, `WorkerHealth`\n- Из `plba.core`: `ConfigurationManager`, `RuntimeManager`, `ServiceContainer`\n- Из `plba.health`: `HealthRegistry`\n- Из `plba.logging`: `LogManager`\n- Из `plba.queue`: `InMemoryTaskQueue`\n- Из `plba.tracing`: `MySqlTraceTransport`, `NoOpTraceTransport`, `TraceService`\n- Из `plba.workflow`: различные классы для работы с workflow\n\nЭто инициализационный скрипт пакета `plba`, обеспечивающий доступ ко всем основным функциональным блокам пакета.", "answer_mode": "answered", "path_scope": [ "src/plba/__init__.py" @@ -322,7 +322,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 43 + "C0_SOURCE_CHUNKS": 24 } } }, @@ -334,6 +334,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -373,8 +376,44 @@ "failure_reasons": [], "evidence_count": 1 }, + "evidence_gate_input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 25, + "pre_evidence_gate": 1, + "llm": 4851, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -412,6 +451,133 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 25 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/plba/__init__.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/plba/__init__.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 24 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4851 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md new file mode 100644 index 0000000..60f4d37 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md @@ -0,0 +1,250 @@ +# plba-v2-open-file-public-api + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/plba/__init__.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 1, + "llm_answer": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: несколько контрактов, таких как `ApplicationModule`, `ConfigProvider`, `Worker`, `WorkerHealth`\n- Из `plba.core`: `ConfigurationManager`, `RuntimeManager`, `ServiceContainer`\n- Из `plba.health`: `HealthRegistry`\n- Из `plba.logging`: `LogManager`\n- Из `plba.queue`: `InMemoryTaskQueue`\n- Из `plba.tracing`: `MySqlTraceTransport`, `NoOpTraceTransport`, `TraceService`\n- Из `plba.workflow`: различные классы для работы с workflow\n\nЭто инициализационный скрипт пакета `plba`, обеспечивающий доступ ко всем основным функциональным блокам пакета.", + "answer_mode": "answered", + "path_scope": [ + "src/plba/__init__.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 25 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/plba/__init__.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/plba/__init__.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 24 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4851 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/plba/__init__.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/plba/__init__.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 1 + }, + "evidence_gate_input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: н" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 25, + "pre_evidence_gate": 1, + "llm": 4851, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json similarity index 79% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json index 7d7cfe4..6ddbd1d 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/app_runtime/core/runtime.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 1, - "llm_answer": "Путь: src/app_runtime/core/runtime.py\n\nВ этом файле содержится определение класса `RuntimeManager`. В примере приведено начало класса с инициализатором (`__init__`) и некоторыми атрибутами и параметрами, такими как `ACTION_TIMEOUT_SECONDS`, `ACTION_POLL_INTERVAL_SECONDS`, а также параметрами конфигурации и сервисов, которые могут передаваться при создании экземпляра класса.", + "llm_answer": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `ConfigurationManager`\n- `services`: экземпляр `ServiceContainer`\n- `traces`: экземпляр `TraceService`\n- `health`: экземпляр `HealthRegistry`\n- `logs`: экземпляр `LogManager`\n- `workers`: экземпляр `WorkerSupervisor`\n- `control_plane`: экземпляр `ControlPlaneService`\n\nВсе эти поля могут принимать значения по умолчанию, если при создании объекта явные аргументы не указаны.", "answer_mode": "answered", "path_scope": [ "src/app_runtime/core/runtime.py" @@ -322,7 +322,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 218 + "C0_SOURCE_CHUNKS": 136 } } }, @@ -334,6 +334,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -373,8 +376,44 @@ "failure_reasons": [], "evidence_count": 1 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 137, + "pre_evidence_gate": 1, + "llm": 3254, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -412,6 +451,133 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 137 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 136 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3254 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md new file mode 100644 index 0000000..271d2e1 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md @@ -0,0 +1,250 @@ +# plba-v2-open-file-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/app_runtime/core/runtime.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 1, + "llm_answer": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `ConfigurationManager`\n- `services`: экземпляр `ServiceContainer`\n- `traces`: экземпляр `TraceService`\n- `health`: экземпляр `HealthRegistry`\n- `logs`: экземпляр `LogManager`\n- `workers`: экземпляр `WorkerSupervisor`\n- `control_plane`: экземпляр `ControlPlaneService`\n\nВсе эти поля могут принимать значения по умолчанию, если при создании объекта явные аргументы не указаны.", + "answer_mode": "answered", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 137 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 136 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3254 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 1 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nВ конструкторе (`__init__`) инициализируются следующие поля объекта:\n- `configuration`: экземпляр `Configurat" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 137, + "pre_evidence_gate": 1, + "llm": 3254, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json similarity index 96% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json index 5eae58c..f09dd7f 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-trace-flow-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Покажи как проходит запрос /health в HttpControlAppFactory", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 37, - "llm_answer": "Поток выполнения запроса `/health` в `HttpControlAppFactory` выглядит следующим образом:\n\n1. Запрос приходит на маршрут `/health`.\n2. Контроллер вызывает метод `health()` внутри фабрики, который объявлен в классе `HttpControlAppFactory`.\n3. Внутри метода `health()` фабрика ожидает асинхронный результат от провайдера здоровья (`health_provider`), представляющего состояние системы.\n4. Результат передается в виде объекта `HealthPayload`, содержащего статус (\"ok\" или иное).\n5. На основе статуса определяется HTTP-код ответа: 200 при успешном состоянии, иначе 503.\n6. Ответ формируется с использованием JSON формата.\n\nТаким образом, ключевой элемент — провайдер здоровья, определяющий текущее состояние системы и возвращающий соответствующий объект состояния.", + "llm_answer": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health` вызывается этот обработчик, который асинхронно вызывает провайдер здоровья (`health_provider`), переданный в фабрику.\n4. Приложение обернуто middleware для логирования времени ответа, которое добавляется в заголовок X-Response-Time-Ms.\n\nЦепочка вызовов завершается на уровне фабрики, конкретных имплементаций провайдера здоровья в данном контексте нет.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1769,36 +1769,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1826,6 +1806,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1849,6 +1836,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3270,11 +3291,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 55, - "C0_SOURCE_CHUNKS": 28, - "C4_SEMANTIC_ROLES": 17, - "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 11 + "C1_SYMBOL_CATALOG": 67, + "C0_SOURCE_CHUNKS": 27, + "C4_SEMANTIC_ROLES": 22, + "C2_DEPENDENCY_GRAPH": 60, + "C3_ENTRYPOINTS": 19 } } }, @@ -3290,6 +3311,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3357,12 +3381,41 @@ "failure_reasons": [], "evidence_count": 37 }, + "evidence_gate_input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 169, - "pre_evidence_gate": 0, - "llm": 1342 + "router": 1, + "retrieval": 197, + "pre_evidence_gate": 1, + "llm": 3593, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -4716,7 +4769,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -4729,7 +4782,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 169 + "retrieval": 197 }, "output": { "rag_count": 37, @@ -4788,11 +4841,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 55, - "C0_SOURCE_CHUNKS": 28, - "C4_SEMANTIC_ROLES": 17, - "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 11 + "C1_SYMBOL_CATALOG": 67, + "C0_SOURCE_CHUNKS": 27, + "C4_SEMANTIC_ROLES": 22, + "C2_DEPENDENCY_GRAPH": 60, + "C3_ENTRYPOINTS": 19 } } }, @@ -4800,36 +4853,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 37 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1342 + "llm": 3593 }, "output": { "prompt_name": "code_qa_trace_flow_answer", - "answer_preview": "Поток выполнения запроса `/health` в `HttpControlAppFactory` выглядит следующим образом:\n\n1. Запрос приходит на маршрут `/health`.\n2. Контроллер вызывает метод `health()` внутри фабрики, который объявлен в классе `HttpControlAppFactory`.\n3. Внутри метода `health()` фабрика ожидает асинхронный резуль" + "answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md new file mode 100644 index 0000000..2b7404a --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md @@ -0,0 +1,306 @@ +# plba-v2-trace-flow-health-endpoint + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Покажи как проходит запрос /health в HttpControlAppFactory + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 37, + "llm_answer": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health` вызывается этот обработчик, который асинхронно вызывает провайдер здоровья (`health_provider`), переданный в фабрику.\n4. Приложение обернуто middleware для логирования времени ответа, которое добавляется в заголовок X-Response-Time-Ms.\n\nЦепочка вызовов завершается на уровне фабрики, конкретных имплементаций провайдера здоровья в данном контексте нет.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "health", + "HttpControlAppFactory" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 197 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlAppFactory", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 67, + "C0_SOURCE_CHUNKS": 27, + "C4_SEMANTIC_ROLES": 22, + "C2_DEPENDENCY_GRAPH": 60, + "C3_ENTRYPOINTS": 19 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3593 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Покажи как проходит запрос /health в HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 10, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 37 + }, + "evidence_gate_input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос /health обрабатывается следующим образом:\n\n1. В файле `http_app.py` класс `HttpControlAppFactory` создаёт объект FastAPI с маршрутом `/health`.\n2. Маршрут `/health` сопоставлен с функцией-обработчиком `health`, определённой внутри фабрики на строках 31–34.\n3. При обращении к маршруту `/health" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 197, + "pre_evidence_gate": 1, + "llm": 3593, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json similarity index 96% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json index f9f57c2..95b4a91 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-trace-flow-runtime-start", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Покажи поток выполнения при запуске RuntimeManager", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 37, - "llm_answer": "При запуске `RuntimeManager` выполняются следующие основные шаги:\n\n1. В `bootstrap.py` создаётся экземпляр `RuntimeManager`.\n2. В `core/runtime.py` инициализируется объект `RuntimeManager`, вызывая его конструктор.\n3. Далее выполняется регистрация базовых сервисов через метод `_register_core_services`.\n4. Запускаются каналы управления с помощью метода `start` объекта `ControlPlaneService`.\n5. Каналы управления начинают свою работу через асинхронный запуск метода `_start_async`.\n6. Управление веб-приложением осуществляется через создание экземпляра `HttpControlChannel`, который использует сервер `UvicornThreadRunner` для запуска HTTP приложения.\n\nПолностью проследить весь поток данных не удалось из-за недостаточного количества информации.", + "llm_answer": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри конструктора, вызывая сам конструктор (`__init__`) и регистрируя основные сервисы методом `_register_core_services`.\n\n2. Начальная инициализация состояния:\n - Внутри конструктора происходит начальное чтение и запись атрибутов состояния, необходимых для работы менеджера.\n\n3. Запуск менеджера:\n - После полной инициализации выполняется метод `start`, который приводит `RuntimeManager` в активное состояние и начинает обработку запросов.\n\nПоток данных включает в себя загрузку конфигурации, создание и регистрацию сервисов, а также переход в рабочее состояние.\n\nДальнейшее восстановление потока возможно только по дополнительным данным.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -1835,36 +1835,16 @@ } ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1892,6 +1872,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1915,6 +1902,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3384,11 +3405,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 39, - "C0_SOURCE_CHUNKS": 24, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 20 + "C1_SYMBOL_CATALOG": 52, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 23, + "C2_DEPENDENCY_GRAPH": 63, + "C3_ENTRYPOINTS": 22 } } }, @@ -3404,6 +3425,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3471,12 +3495,41 @@ "failure_reasons": [], "evidence_count": 37 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 153, - "pre_evidence_gate": 0, - "llm": 1356 + "router": 1, + "retrieval": 187, + "pre_evidence_gate": 1, + "llm": 4010, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -4878,7 +4931,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -4891,7 +4944,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 153 + "retrieval": 187 }, "output": { "rag_count": 37, @@ -4950,11 +5003,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 39, - "C0_SOURCE_CHUNKS": 24, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 20 + "C1_SYMBOL_CATALOG": 52, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 23, + "C2_DEPENDENCY_GRAPH": 63, + "C3_ENTRYPOINTS": 22 } } }, @@ -4962,36 +5015,62 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 37 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1356 + "llm": 4010 }, "output": { "prompt_name": "code_qa_trace_flow_answer", - "answer_preview": "При запуске `RuntimeManager` выполняются следующие основные шаги:\n\n1. В `bootstrap.py` создаётся экземпляр `RuntimeManager`.\n2. В `core/runtime.py` инициализируется объект `RuntimeManager`, вызывая его конструктор.\n3. Далее выполняется регистрация базовых сервисов через метод `_register_core_service" + "answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md new file mode 100644 index 0000000..4a32a37 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md @@ -0,0 +1,305 @@ +# plba-v2-trace-flow-runtime-start + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Покажи поток выполнения при запуске RuntimeManager + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 37, + "llm_answer": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри конструктора, вызывая сам конструктор (`__init__`) и регистрируя основные сервисы методом `_register_core_services`.\n\n2. Начальная инициализация состояния:\n - Внутри конструктора происходит начальное чтение и запись атрибутов состояния, необходимых для работы менеджера.\n\n3. Запуск менеджера:\n - После полной инициализации выполняется метод `start`, который приводит `RuntimeManager` в активное состояние и начинает обработку запросов.\n\nПоток данных включает в себя загрузку конфигурации, создание и регистрацию сервисов, а также переход в рабочее состояние.\n\nДальнейшее восстановление потока возможно только по дополнительным данным.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 187 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 52, + "C0_SOURCE_CHUNKS": 25, + "C4_SEMANTIC_ROLES": 23, + "C2_DEPENDENCY_GRAPH": 63, + "C3_ENTRYPOINTS": 22 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4010 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Покажи поток выполнения при запуске RuntimeManager", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 10, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 37 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации и сервисов:\n - В конструкторе `RuntimeManager.__init__` инициализируется конфигурация через поле `configuration`, загружаются файлы конфигурации с помощью метода `add_config_file`.\n - Создаются сервисы внутри" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 187, + "pre_evidence_gate": 1, + "llm": 4010, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/summary.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/summary.md new file mode 100644 index 0000000..9717c0f --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_174008/summary.md @@ -0,0 +1,80 @@ +# pipeline_setup_v3 summary + +Passed: 18/18 + +| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | +|------|------|------|-------|-------------------|------------|------| +| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-public-api | full_chain | Открой файл src/plba/__init__.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-trace-service | full_chain | Объясни как работает класс TraceService | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-create-runtime | full_chain | Что делает функция create_runtime? | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-trace-service | full_chain | Где тесты для TraceService? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-create-runtime | full_chain | Где тесты для create_runtime? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-workflow-runtime-factory-negative | full_chain | Где тесты для WorkflowRuntimeFactory? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-control-plane | full_chain | Найди точки входа HTTP control plane | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:7, C3_ENTRYPOINTS:3 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-health-endpoint | full_chain | Покажи как проходит запрос /health в HttpControlAppFactory | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-control-plane | full_chain | Какие компоненты участвуют в ControlPlaneService? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | — | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✓ | + +## LLM Answers +- **plba-v2-open-file-runtime** + Query: Открой файл src/app_runtime/core/runtime.py + > В файле \`src/app\_runtime/core/runtime.py\` определён класс \`RuntimeManager\`. У него есть несколько атрибутов класса: \- \`ACTION\_TIMEOUT\_SECONDS = 10.0\` \- \`ACTION\_POLL\_INTERVAL\_SECONDS = 0.05\` В конструкторе \(\`\_\_init\_\_\`\) инициализируются следующие поля объекта: \- \`configuration\`: экземпляр \`ConfigurationManager\` \- \`services\`: экземпляр \`ServiceContainer\` \- \`traces\`: экземпляр \`TraceService\` \- \`health\`: экземпляр \`HealthRegistry\` \- \`logs\`: экземпляр \`LogManager\` \- \`workers\`: экземпляр \`WorkerSupervisor\` \- \`control\_plane\`: экземпляр \`ControlPlaneService\` Все эти поля могут принимать значения по умолчанию, если при создании объекта явные аргументы не указаны. +- **plba-v2-open-file-public-api** + Query: Открой файл src/plba/__init__.py + > Файл \`src/plba/\_\_init\_\_.py\` импортирует следующие основные компоненты: \- Из \`plba.bootstrap\`: \`create\_runtime\` \- Из \`plba.config\`: \`ConfigFileLoader\`, \`FileConfigProvider\` \- Из \`plba.control\`: \`ControlActionSet\`, \`ControlChannel\`, \`ControlPlaneService\`, \`HttpControlChannel\` \- Из \`plba.contracts\`: несколько контрактов, таких как \`ApplicationModule\`, \`ConfigProvider\`, \`Worker\`, \`WorkerHealth\` \- Из \`plba.core\`: \`ConfigurationManager\`, \`RuntimeManager\`, \`ServiceContainer\` \- Из \`plba.health\`: \`HealthRegistry\` \- Из \`plba.logging\`: \`LogManager\` \- Из \`plba.queue\`: \`InMemoryTaskQueue\` \- Из \`plba.tracing\`: \`MySqlTraceTransport\`, \`NoOpTraceTransport\`, \`TraceService\` \- Из \`plba.workflow\`: различные классы для работы с workflow Это инициализационный скрипт пакета \`plba\`, обеспечивающий доступ ко всем основным функциональным блокам пакета. +- **plba-v2-explain-runtime-manager** + Query: Объясни как работает класс RuntimeManager + > Класс \`RuntimeManager\` определён в файле \`src/app\_runtime/core/runtime.py\` и имеет responsibilities характерные для менеджера: управляет конфигурацией, состоянием и участвует в потоках данных через 50 срезов dataflow. Конструктор \`RuntimeManager.\_\_init\_\_\` инициализирует объект и вызывает: \- \`RuntimeManager.configuration\` \- \`RuntimeManager.add\_config\_file\` Связи и вызовы других сущностей не указаны явно в данном контексте, но известно, что \`RuntimeManager\` используется в службах контроля \(\`ControlPlaneService\`\) и взаимодействует с ними через методы старта, стопа и получения снимков состояния. Дополнительные детали о взаимодействии с другими компонентами отсутствуют в представленном контексте. +- **plba-v2-explain-trace-service** + Query: Объясни как работает класс TraceService + > Класс \`TraceService\` находится в файле \`src/app\_runtime/tracing/service.py\`. Он наследуется от \`TraceContextFactory\`. Основные компоненты: \- \*\*Конструктор \(\`\_\_init\_\_\`\)\*\*: принимает параметры \`transport\` и \`store\`, инициализирует транспорт для трассировки и хранилище контекста трассировки. Если транспорт или хранилище не указаны, используются реализации по умолчанию: \`NoOpTraceTransport\(\)\` и \`TraceContextStore\(\)\`. \- \*\*Метод \`create\_context\`\*\*: создаёт новый контекст трассировки, принимая параметры \`alias\`, \`parent\_id\`, \`kind\` и \`attrs\`. В нём создаётся запись контекста трассировки с уникальным идентификатором, текущим временем и переданными параметрами, затем эта запись сохраняется в хранилище. Также определены методы \`open\_context\`, \`close\_context\`, \`current\_trace\_id\`, но их реализация не приведена в контексте. Осторожный вывод: \`TraceService\` используется для управл… +- **plba-v2-explain-create-runtime** + Query: Что делает функция create_runtime? + > Функция \`create\_runtime\` определена в модуле \`src/plba/bootstrap.py\`. Она создаёт и настраивает экземпляр \`RuntimeManager\`, регистрируя модуль приложения и, при необходимости, конфигурационные файлы и HTTP\-канал управления. Основные действия функции: \- Инициализирует объект \`RuntimeManager\`. \- Если указан путь к конфигурационному файлу \(\`config\_path\`\), добавляет его в менеджер. \- Если включено управление через HTTP \(\`enable\_http\_control\`\), регистрирует HTTP\-канал управления в плоскости контроля. \- Регистрирует модуль приложения в менеджере времени выполнения. \- Возвращает настроенный объект \`RuntimeManager\`. Входные параметры: \- \`module\`: экземпляр \`ApplicationModule\`. \- \`config\_path\`: опциональный путь к конфигурационному файлу. \- \`enable\_http\_control\`: флаг включения HTTP\-контроля. \- \`control\_host\`, \`control\_port\`, \`control\_timeout\`: параметры подключения для HTTP\-… +- **plba-v2-explain-local-http-channel** + Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? + > Класс HttpControlChannel в файле http\_channel.py наследует ControlChannel и реализует HTTP\-канал управления. Он имеет конструктор с параметрами хост, порт и таймаут, где инициализирует runner \(используя Uvicorn для запуска сервера\) и factory для создания FastAPI\-приложения. Метод start запускает сервер с приложением, используя фабрику и передавая обработчики здоровья и действий. Методы \_health\_response и \_action\_response отвечают за обработку запросов к здоровью сервиса и выполнение действий соответственно. Структура класса ориентирована на создание отдельного HTTP\-канала для управления приложением через HTTP\-запросы. +- **plba-v2-find-tests-runtime-manager** + Query: Где тесты для RuntimeManager? + > Прямые тесты для \`RuntimeManager\` находятся в файле \`tests/test\_runtime.py\`. Косвенные тесты: \- В файле \`tests/test\_business\_control\_actions.py\` есть тесты, использующие компоненты контроля, которые взаимодействуют с \`RuntimeManager\`. +- **plba-v2-find-tests-trace-service** + Query: Где тесты для TraceService? + > Прямые тесты для TraceService находятся в файле \`tests/test\_runtime.py\`: \- \`test\_trace\_service\_allows\_messages\_without\_status\`: проверяет возможность отправки сообщений без статуса. \- \`test\_trace\_service\_writes\_contexts\_and\_messages\`: проверяет запись контекстов и сообщений. \- \`test\_trace\_service\_supports\_debug\_warning\_and\_error\_levels\`: проверяет поддержку уровней debug, warning и error. +- **plba-v2-find-tests-create-runtime** + Query: Где тесты для create_runtime? + > Прямые тесты для \`create\_runtime\` не найдены. Ближайший косвенный тест: \- \`tests/test\_runtime.py::test\_public\_plba\_package\_exports\_runtime\_builder\_and\_worker\_contract\` \- Проверяет экспорт пакета plba и доступность создания runtime, включая \`create\_runtime\`. +- **plba-v2-find-tests-workflow-runtime-factory-negative** + Query: Где тесты для WorkflowRuntimeFactory? + > Insufficient evidence for a confident answer. No test candidates found. +- **plba-v2-find-entrypoints-control-plane** + Query: Найди точки входа HTTP control plane + > Подтверждённые HTTP routes: \- GET /health, объявлен в src/app\_runtime/control/http\_app.py, строки 31\-34, обработчик health \- GET /actions/\{action\}, объявлен в src/app\_runtime/control/http\_app.py, строки 38\-42, обработчик action \- POST /actions/\{action\}, объявлен в src/app\_runtime/control/http\_app.py, строки 38\-42, обработчик action Кандидаты на входы не требуются, так как все маршруты уже подтверждены. +- **plba-v2-find-entrypoints-health-endpoint** + Query: Где health endpoint? + > Подтверждённая точка входа для health endpoint: GET /health, declared in src/app\_runtime/control/http\_app.py, lines 31\-34, handler function named 'health'. +- **plba-v2-trace-flow-runtime-start** + Query: Покажи поток выполнения при запуске RuntimeManager + > При запуске \`RuntimeManager\` выполняются следующие шаги: 1. Инициализация конфигурации и сервисов: \- В конструкторе \`RuntimeManager.\_\_init\_\_\` инициализируется конфигурация через поле \`configuration\`, загружаются файлы конфигурации с помощью метода \`add\_config\_file\`. \- Создаются сервисы внутри конструктора, вызывая сам конструктор \(\`\_\_init\_\_\`\) и регистрируя основные сервисы методом \`\_register\_core\_services\`. 2. Начальная инициализация состояния: \- Внутри конструктора происходит начальное чтение и запись атрибутов состояния, необходимых для работы менеджера. 3. Запуск менеджера: \- После полной инициализации выполняется метод \`start\`, который приводит \`RuntimeManager\` в активное состояние и начинает обработку запросов. Поток данных включает в себя загрузку конфигурации, создание и регистрацию сервисов, а также переход в рабочее состояние. Дальнейшее восстановление поток… +- **plba-v2-trace-flow-health-endpoint** + Query: Покажи как проходит запрос /health в HttpControlAppFactory + > Запрос /health обрабатывается следующим образом: 1. В файле \`http\_app.py\` класс \`HttpControlAppFactory\` создаёт объект FastAPI с маршрутом \`/health\`. 2. Маршрут \`/health\` сопоставлен с функцией\-обработчиком \`health\`, определённой внутри фабрики на строках 31–34. 3. При обращении к маршруту \`/health\` вызывается этот обработчик, который асинхронно вызывает провайдер здоровья \(\`health\_provider\`\), переданный в фабрику. 4. Приложение обернуто middleware для логирования времени ответа, которое добавляется в заголовок X\-Response\-Time\-Ms. Цепочка вызовов завершается на уровне фабрики, конкретных имплементаций провайдера здоровья в данном контексте нет. +- **plba-v2-architecture-runtime-manager** + Query: Какие компоненты участвуют в RuntimeManager? + > Компоненты, участвующие в RuntimeManager: 1. \*\*ControlPlaneService\*\* \- Регистрирует каналы управления \(\_register\_channel\_\), запускается асинхронно \(\_start\_async\), останавливается \(\_stop\_, \_stop\_async\_\). \- Файлы: \`service.py\` \(строки 14–52\). 2. \*\*HttpControlAppFactory\*\* \- Фабрика для создания HTTP\-приложений контроля. \- Файл: \`http\_app.py\` \(строки 15–53\). 3. \*\*UvicornThreadRunner\*\* \- Выполняет работу в потоке Uvicorn. \- Файл: \`http\_runner.py\` \(строки 10–61\). 4. \*\*HttpControlChannel\*\* \- Канал HTTP\-контроля. \- Файл: \`http\_channel.py\` \(строки 12–57\). 5. \*\*WorkflowPersistence\*\* \- Сохраняет состояние рабочих процессов. \- Файл: \`workflow\_persistence.py\` \(строки 8–54\). 6. \*\*InMemoryTaskQueue\*\* \- Очередь задач в памяти. \- Файл: \`in\_memory.py\` \(строки 9–38\). 7. \*\*ConfigFileLoader\*\* \- Загружает конфигурационные файлы. \- Файл: \`file\_loader.py\` \(строки 11–48\). 8. \*\*TraceContextSt… +- **plba-v2-architecture-control-plane** + Query: Какие компоненты участвуют в ControlPlaneService? + > Компоненты, участвующие в ControlPlaneService: \- \*\*ControlActionSet\*\* – модель для управления действиями. \- \*\*ControlChannel\*\* – абстрактный базовый класс каналов контроля с методами start и stop. \- \*\*UvicornThreadRunner\*\* – этап пайплайна для многопоточного запуска HTTP сервера. \- \*\*HttpControlChannel\*\* – канал HTTP\-контроля, этап пайплайна. \- \*\*HttpControlAppFactory\*\* – фабрика создания HTTP\-приложения контроля. \- \*\*WorkflowPersistence\*\* – сохранение состояний рабочих процессов. \- \*\*InMemoryTaskQueue\*\* – очередь задач в памяти. \- \*\*ConfigFileLoader\*\* – загрузчик конфигурационных файлов. \- \*\*TraceContextStore\*\* – хранилище контекстов трассировки. \- \*\*WorkerSupervisor\*\* – надзор за рабочими процессами. \- \*\*WorkflowEngine\*\* – движок обработки рабочих процессов. Связи внутри ControlPlaneService: \- \_channels – атрибут, используемый во многих методах сервиса. \- register\_… +- **plba-v2-explain-nonexistent-symbol** + Query: Объясни класс RuntimeFactoryManager + > Сущность RuntimeFactoryManager не найдена в доступном коде. +- **plba-v2-open-file-nonexistent** + Query: Открой файл src/app_runtime/core/missing_runtime.py + > Файл src/app\_runtime/core/missing\_runtime.py не найден. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json similarity index 90% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json index 246a76b..c82b8f8 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-architecture-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Какие компоненты участвуют в ControlPlaneService?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Подтвержденные связи и роли компонентов в контексте ControlPlaneService:\n\n### Компоненты и их роли\n\n1. **ControlPlaneService**\n - Роль: pipeline_stage\n - Описание: Инициализирует каналы управления и управляет ими.\n \n2. **ControlChannel**\n - Роль: model\n - Описание: Абстрактный класс для каналов управления с методами старта и остановки.\n\n3. **ControlActionSet**\n - Роль: model\n - Описание: Представляет набор действий контроля.\n\n4. **UvicornThreadRunner**\n - Роль: pipeline_stage\n - Описание: Управляет uvicorn сервером и участвует в потоках данных.\n\n5. **HttpControlChannel**\n - Роль: pipeline_stage\n - Описание: Канал управления HTTP-соединениями, участвующий в потоках данных.\n\n6. **HttpControlAppFactory**\n - Роль: factory\n - Описание: Фабрика для создания fastAPI приложений.\n\n7. **WorkflowPersistence**\n - Роль: pipeline_stage\n - Описание: Хранит информацию о процессах и взаимодействует с ними.\n\n8. **InMemoryTaskQueue**\n - Роль: pipeline_stage\n - Описание: Очередь задач, используемая для хранения промежуточных результатов.\n\n9. **ConfigFileLoader**\n - Роль: pipeline_stage\n - Описание: Загружает конфигурационные файлы и участвует в управлении состоянием приложения.\n\n10. **TraceContextStore**\n - Роль: pipeline_stage\n - Описание: Сохраняет контекст трассировки и управляет им.\n\n11. **WorkerSupervisor**\n - Роль: pipeline_stage\n - Описание: Наблюдает за рабочими процессами и обеспечивает их корректное выполнение.\n\n12. **WorkflowEngine**\n - Роль: pipeline_stage\n - Описание: Координирует выполнение рабочих процессов и управление ими.\n\n### Ограничения и замечания\n\nВсе перечисленные компоненты прямо или косвенно связаны с ControlPlaneService через зависимости или вызовы методов внутри ControlPlaneService. Они активно участвуют в его работе и обеспечивают функциональность и инфраструктуру, необходимую для выполнения его обязанностей.", + "llm_answer": "**ControlPlaneService** является главным компонентом, управляющим жизненным циклом контролируемых каналов.\n\nКомпоненты:\n- **ControlPlaneService**\n- **ControlPlaneService.__init__**: инициализирует сервис, регистрирует каналы и запускает асинхронные операции.\n- **ControlPlaneService.start**: начинает работу сервиса, вызывая asyncio.run и читая атрибут _channels.\n- **ControlPlaneService.register_channel**: регистрирует канал, читая атрибут _channels.\n- **ControlPlaneService.stop**, **ControlPlaneService._stop_async**: останавливают сервисы.\n- **ControlPlaneService._start_async**: отвечает за асинхронный старт.\n- **ControlChannel**: абстрактный базовый класс всех каналов контроля с методами start и stop.\n\nСвязи между компонентами:\n- Инициализация (ControlPlaneService.__init__) выполняет dataflow_slice для методов регистрации и старта.\n- Метод старта (ControlPlaneService.start) вызывает asyncio.run и зависит от атрибута _channels.\n- Регистрация канала (ControlPlaneService.register_channel) использует данные из атрибута _channels.\n\nТаким образом, ControlPlaneService координирует работу зарегистрированных каналов (_channels), обеспечивая их правильный запуск и остановку.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -120,12 +120,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "ControlPlaneService", "alternatives": [ + "ControlPlaneService", + "ControlPlaneService", + "ControlPlaneService", + "ControlPlaneService", "ControlPlaneService" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1258,6 +1262,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1298,6 +1307,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1338,6 +1352,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1378,6 +1397,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1418,6 +1442,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1458,6 +1487,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 22, + "end_line": 22, + "edge_type": "calls", + "source": "ControlPlaneService.start", + "target": "asyncio.run", "metadata": { "edge_id": "4e0b3147fb867d48d26567570c259f4052a739e3098133802d4b8bafcf03be6b", "edge_type": "calls", @@ -1482,6 +1516,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 17, + "end_line": 17, + "edge_type": "reads_attr", + "source": "ControlPlaneService.register_channel", + "target": "ControlPlaneService._channels", "metadata": { "edge_id": "3101fdc99a7a9c5aebf18a024bc148d37b348248a6fd02b95724dff280f2908a", "edge_type": "reads_attr", @@ -1506,6 +1545,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 20, + "end_line": 20, + "edge_type": "reads_attr", + "source": "ControlPlaneService.start", + "target": "ControlPlaneService._channels", "metadata": { "edge_id": "9452e50ef27d47c30ee1c311c48fe73ecddbf7a6dbcf967a6345e98222d9f71a", "edge_type": "reads_attr", @@ -1529,37 +1573,115 @@ "content": "ControlPlaneService.start reads_attr ControlPlaneService._channels" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + }, + { + "path": "src/app_runtime/queue/in_memory.py", + "title": "InMemoryTaskQueue", + "symbol": "InMemoryTaskQueue", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)" + }, + { + "path": "src/app_runtime/config/file_loader.py", + "title": "ConfigFileLoader", + "symbol": "ConfigFileLoader", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)" + }, + { + "path": "src/app_runtime/tracing/store.py", + "title": "TraceContextStore", + "symbol": "TraceContextStore", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/workers/supervisor.py", + "title": "WorkerSupervisor", + "symbol": "WorkerSupervisor", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/workflow/engine/workflow_engine.py", + "title": "WorkflowEngine", + "symbol": "WorkflowEngine", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1587,6 +1709,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1610,6 +1739,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2881,11 +3044,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 40, + "C4_SEMANTIC_ROLES": 81, "C3_ENTRYPOINTS": 20, "C2_DEPENDENCY_GRAPH": 60, - "C1_SYMBOL_CATALOG": 25, - "C0_SOURCE_CHUNKS": 17 + "C1_SYMBOL_CATALOG": 33, + "C0_SOURCE_CHUNKS": 37 } } }, @@ -2901,6 +3064,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2915,7 +3081,7 @@ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2968,8 +3134,44 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "**ControlPlaneService** — центральный компонент, отвечающий за инициализацию, запуск и остановку контролируемых каналов.\n\nОсновные компоненты:\n- **ControlPlaneService**: главный класс сервиса управления каналами контроля.\n- **ControlPlaneService.__init__**: метод инициализации, выполняющий dataflow_", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": true, + "final_answer_preview": "**ControlPlaneService** является главным компонентом, управляющим жизненным циклом контролируемых каналов.\n\nКомпоненты:\n- **ControlPlaneService**\n- **ControlPlaneService.__init__**: инициализирует сервис, регистрирует каналы и запускает асинхронные операции.\n- **ControlPlaneService.start**: начинает" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 233, + "pre_evidence_gate": 1, + "llm": 6272, + "post_evidence_gate": 1, + "repair": 5760, + "post_evidence_gate_recheck": 1 + } }, "rag_rows": [ { @@ -4166,6 +4368,154 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 233 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "ControlPlaneService", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 81, + "C3_ENTRYPOINTS": 20, + "C2_DEPENDENCY_GRAPH": 60, + "C1_SYMBOL_CATALOG": 33, + "C0_SOURCE_CHUNKS": 37 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 6272 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "**ControlPlaneService** — центральный компонент, отвечающий за инициализацию, запуск и остановку контролируемых каналов.\n\nОсновные компоненты:\n- **ControlPlaneService**: главный класс сервиса управления каналами контроля.\n- **ControlPlaneService.__init__**: метод инициализации, выполняющий dataflow_", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 1, + "repair": 5760 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "**ControlPlaneService** — центральный компонент, отвечающий за инициализацию, запуск и остановку контролируемых каналов.\n\nОсновные компоненты:\n- **ControlPlaneService**: главный класс сервиса управления каналами контроля.\n- **ControlPlaneService.__init__**: метод инициализации, выполняющий dataflow_", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": true, + "final_answer_preview": "**ControlPlaneService** является главным компонентом, управляющим жизненным циклом контролируемых каналов.\n\nКомпоненты:\n- **ControlPlaneService**\n- **ControlPlaneService.__init__**: инициализирует сервис, регистрирует каналы и запускает асинхронные операции.\n- **ControlPlaneService.start**: начинает" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md new file mode 100644 index 0000000..11a4dff --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-control-plane.md @@ -0,0 +1,307 @@ +# plba-v2-architecture-control-plane + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Какие компоненты участвуют в ControlPlaneService? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "**ControlPlaneService** является главным компонентом, управляющим жизненным циклом контролируемых каналов.\n\nКомпоненты:\n- **ControlPlaneService**\n- **ControlPlaneService.__init__**: инициализирует сервис, регистрирует каналы и запускает асинхронные операции.\n- **ControlPlaneService.start**: начинает работу сервиса, вызывая asyncio.run и читая атрибут _channels.\n- **ControlPlaneService.register_channel**: регистрирует канал, читая атрибут _channels.\n- **ControlPlaneService.stop**, **ControlPlaneService._stop_async**: останавливают сервисы.\n- **ControlPlaneService._start_async**: отвечает за асинхронный старт.\n- **ControlChannel**: абстрактный базовый класс всех каналов контроля с методами start и stop.\n\nСвязи между компонентами:\n- Инициализация (ControlPlaneService.__init__) выполняет dataflow_slice для методов регистрации и старта.\n- Метод старта (ControlPlaneService.start) вызывает asyncio.run и зависит от атрибута _channels.\n- Регистрация канала (ControlPlaneService.register_channel) использует данные из атрибута _channels.\n\nТаким образом, ControlPlaneService координирует работу зарегистрированных каналов (_channels), обеспечивая их правильный запуск и остановку.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "ControlPlaneService" + ], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 233 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "ControlPlaneService", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 81, + "C3_ENTRYPOINTS": 20, + "C2_DEPENDENCY_GRAPH": 60, + "C1_SYMBOL_CATALOG": 33, + "C0_SOURCE_CHUNKS": 37 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 6272 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "**ControlPlaneService** — центральный компонент, отвечающий за инициализацию, запуск и остановку контролируемых каналов.\n\nОсновные компоненты:\n- **ControlPlaneService**: главный класс сервиса управления каналами контроля.\n- **ControlPlaneService.__init__**: метод инициализации, выполняющий dataflow_", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 1, + "repair": 5760 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "**ControlPlaneService** — центральный компонент, отвечающий за инициализацию, запуск и остановку контролируемых каналов.\n\nОсновные компоненты:\n- **ControlPlaneService**: главный класс сервиса управления каналами контроля.\n- **ControlPlaneService.__init__**: метод инициализации, выполняющий dataflow_", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": true, + "final_answer_preview": "**ControlPlaneService** является главным компонентом, управляющим жизненным циклом контролируемых каналов.\n\nКомпоненты:\n- **ControlPlaneService**\n- **ControlPlaneService.__init__**: инициализирует сервис, регистрирует каналы и запускает асинхронные операции.\n- **ControlPlaneService.start**: начинает" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "ControlPlaneService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Какие компоненты участвуют в ControlPlaneService?", + "sub_intent": "ARCHITECTURE", + "path_scope": [], + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 12, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "ControlPlaneService", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "ControlPlaneService", + "draft_answer_preview": "**ControlPlaneService** — центральный компонент, отвечающий за инициализацию, запуск и остановку контролируемых каналов.\n\nОсновные компоненты:\n- **ControlPlaneService**: главный класс сервиса управления каналами контроля.\n- **ControlPlaneService.__init__**: метод инициализации, выполняющий dataflow_", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": true, + "final_answer_preview": "**ControlPlaneService** является главным компонентом, управляющим жизненным циклом контролируемых каналов.\n\nКомпоненты:\n- **ControlPlaneService**\n- **ControlPlaneService.__init__**: инициализирует сервис, регистрирует каналы и запускает асинхронные операции.\n- **ControlPlaneService.start**: начинает" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 233, + "pre_evidence_gate": 1, + "llm": 6272, + "post_evidence_gate": 1, + "repair": 5760, + "post_evidence_gate_recheck": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json similarity index 92% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json index 04ff995..bd8c89d 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-architecture-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Какие компоненты участвуют в RuntimeManager?", @@ -10,8 +10,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "В подсистеме RuntimeManager участвуют следующие компоненты:\n\n1. **RuntimeManager** (src/app_runtime/core/runtime.py):\n - Инициализирует конфигурацию и управляет жизненным циклом runtime-пipeline.\n - Создаёт и регистрирует основные сервисы (ControlPlaneService, WorkflowPersistence, InMemoryTaskQueue, ConfigFileLoader, TraceContextStore, WorkerSupervisor).\n\n2. **ControlPlaneService** (src/app_runtime/control/service.py):\n - Служба управления каналами контроля и взаимодействия с внешними сущностями.\n - Регистрирует каналы и запускает асинхронные операции.\n\n3. **WorkflowPersistence** (src/app_runtime/workflow/persistence/workflow_persistence.py):\n - Обеспечивает долговременное хранение workflow-данных.\n\n4. **InMemoryTaskQueue** (src/app_runtime/queue/in_memory.py):\n - Хранит задачи в памяти для временного хранения и обработки.\n\n5. **ConfigFileLoader** (src/app_runtime/config/file_loader.py):\n - Загружает конфигурации из файлов.\n\n6. **TraceContextStore** (src/app_runtime/tracing/store.py):\n - Управляет контекстом трассировки.\n\n7. **WorkerSupervisor** (src/app_runtime/workers/supervisor.py):\n - Контролирует выполнение рабочих задач.\n\nЭти компоненты взаимодействуют через конструктор RuntimeManager, где регистрируются необходимые сервисы и каналы. Управление жизненным циклом и координация работы осуществляется через инициализацию и регистрацию сервисов.", - "answer_mode": "answered", + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager.", + "answer_mode": "degraded", "path_scope": [], "symbol_candidates": [ "RuntimeManager" @@ -120,12 +120,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1306,6 +1310,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1346,6 +1355,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 59, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.start", "metadata": { "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", "edge_type": "dataflow_slice", @@ -1386,6 +1400,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1426,6 +1445,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1466,6 +1490,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1506,6 +1535,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1546,6 +1580,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1586,6 +1625,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 127, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager._register_core_services", "metadata": { "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", "edge_type": "dataflow_slice", @@ -1625,37 +1669,115 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager._register_core_services" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/core/runtime.py", + "title": "RuntimeManager", + "symbol": "RuntimeManager", + "role": "pipeline_stage", + "confidence": 0.67, + "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + }, + { + "path": "src/app_runtime/queue/in_memory.py", + "title": "InMemoryTaskQueue", + "symbol": "InMemoryTaskQueue", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)" + }, + { + "path": "src/app_runtime/config/file_loader.py", + "title": "ConfigFileLoader", + "symbol": "ConfigFileLoader", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)" + }, + { + "path": "src/app_runtime/tracing/store.py", + "title": "TraceContextStore", + "symbol": "TraceContextStore", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/workers/supervisor.py", + "title": "WorkerSupervisor", + "symbol": "WorkerSupervisor", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1683,6 +1805,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1706,6 +1835,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3025,11 +3188,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 28, - "C3_ENTRYPOINTS": 11, - "C2_DEPENDENCY_GRAPH": 58, - "C1_SYMBOL_CATALOG": 25, - "C0_SOURCE_CHUNKS": 16 + "C4_SEMANTIC_ROLES": 41, + "C3_ENTRYPOINTS": 25, + "C2_DEPENDENCY_GRAPH": 70, + "C1_SYMBOL_CATALOG": 30, + "C0_SOURCE_CHUNKS": 22 } } }, @@ -3044,7 +3207,10 @@ "C0_SOURCE_CHUNKS" ], "retrieval_sufficient": true, - "answer_mode": "normal", + "answer_mode": "degraded", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3059,7 +3225,7 @@ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -3112,8 +3278,47 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** — инициализирует конфигурацию и запускает основные сервисы (методы: `__init__`, `start`, `add_config_file`, `_register_core_services`).\n- **ControlPlaneService** — управляет каналами контроля и асинхронными операциями старта ", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_relations", + "too_vague_for_architecture" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 191, + "pre_evidence_gate": 1, + "llm": 6733, + "post_evidence_gate": 1, + "repair": 4344, + "post_evidence_gate_recheck": 1 + } }, "rag_rows": [ { @@ -4355,9 +4560,163 @@ } ], "validation": { - "passed": true, - "action": "return", - "reasons": [] - } + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_relations", + "too_vague_for_architecture" + ] + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "ARCHITECTURE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 191 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C4_SEMANTIC_ROLES", + "C3_ENTRYPOINTS", + "C2_DEPENDENCY_GRAPH", + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C4_SEMANTIC_ROLES": "vector", + "C3_ENTRYPOINTS": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C4_SEMANTIC_ROLES": 12, + "C3_ENTRYPOINTS": 8, + "C2_DEPENDENCY_GRAPH": 8, + "C1_SYMBOL_CATALOG": 6, + "C0_SOURCE_CHUNKS": 4 + }, + "filters_by_layer": { + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C4_SEMANTIC_ROLES": 41, + "C3_ENTRYPOINTS": 25, + "C2_DEPENDENCY_GRAPH": 70, + "C1_SYMBOL_CATALOG": 30, + "C0_SOURCE_CHUNKS": 22 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 6733 + }, + "output": { + "prompt_name": "code_qa_architecture_answer", + "answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** — инициализирует конфигурацию и запускает основные сервисы (методы: `__init__`, `start`, `add_config_file`, `_register_core_services`).\n- **ControlPlaneService** — управляет каналами контроля и асинхронными операциями старта ", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 1, + "repair": 4344 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** — инициализирует конфигурацию и запускает основные сервисы (методы: `__init__`, `start`, `add_config_file`, `_register_core_services`).\n- **ControlPlaneService** — управляет каналами контроля и асинхронными операциями старта ", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_relations", + "too_vague_for_architecture" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md similarity index 52% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md index 2f29970..1046850 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-architecture-runtime-manager.md @@ -1,6 +1,6 @@ # plba-v2-architecture-runtime-manager -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml - runner: agent_runtime - mode: full_chain - passed: True @@ -15,8 +15,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "В подсистеме RuntimeManager участвуют следующие компоненты:\n\n1. **RuntimeManager** — главный менеджер runtime, отвечает за конфигурацию и запуск runtime-потоков (src/app_runtime/core/runtime.py).\n2. **ControlPlaneService** — сервис управления каналами контроля, обеспечивает регистрацию каналов и старт/стоп операций (src/app_runtime/control/service.py).\n3. **ControlChannel** — абстрактный канал управления, определяющий интерфейсы для запуска и остановки канала (src/app_runtime/control/base.py).\n4. **UvicornThreadRunner** — реализует uvicorn thread runner для обработки HTTP-запросов (src/app_runtime/control/http_runner.py).\n5. **HttpControlChannel** — HTTP-канал управления, участвует в управлении состояниями и операциях (src/app_runtime/control/http_channel.py).\n6. **HttpControlAppFactory** — фабрика для создания fastAPI приложений с контролем состояний (src/app_runtime/control/http_app.py).\n7. **WorkflowPersistence** — сохраняет состояние workflow-потоков (src/app_runtime/workflow/persistence/workflow_persistence.py).\n8. **InMemoryTaskQueue** — очередь задач в памяти, используется для хранения и обработки заданий (src/app_runtime/queue/in_memory.py).\n9. **ConfigFileLoader** — загружает конфигурации из файлов (src/app_runtime/config/file_loader.py).\n10. **TraceContextStore** — хранит контекст трассировки для отслеживания выполнения потоков (src/app_runtime/tracing/store.py).\n11. **WorkerSupervisor** — управляет рабочими процессами и их мониторингом (src/app_runtime/workers/supervisor.py).\n\nВсе эти компоненты взаимодействуют через общую инфраструктуру runtime, обмениваясь данными и событиями, участвуя в общем потоке управления и исполнения задач.", - "answer_mode": "answered", + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager.", + "answer_mode": "degraded", "path_scope": [], "symbol_candidates": [ "RuntimeManager" @@ -36,7 +36,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -49,7 +49,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 155 + "retrieval": 191 }, "output": { "rag_count": 33, @@ -108,11 +108,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C4_SEMANTIC_ROLES": 33, - "C3_ENTRYPOINTS": 19, - "C2_DEPENDENCY_GRAPH": 61, - "C1_SYMBOL_CATALOG": 24, - "C0_SOURCE_CHUNKS": 15 + "C4_SEMANTIC_ROLES": 41, + "C3_ENTRYPOINTS": 25, + "C2_DEPENDENCY_GRAPH": 70, + "C1_SYMBOL_CATALOG": 30, + "C0_SOURCE_CHUNKS": 22 } } }, @@ -120,36 +120,65 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 33 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 2995 + "llm": 6733 }, "output": { "prompt_name": "code_qa_architecture_answer", - "answer_preview": "В подсистеме RuntimeManager участвуют следующие компоненты:\n\n1. **RuntimeManager** — главный менеджер runtime, отвечает за конфигурацию и запуск runtime-потоков (src/app_runtime/core/runtime.py).\n2. **ControlPlaneService** — сервис управления каналами контроля, обеспечивает регистрацию каналов и ста" + "answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** — инициализирует конфигурацию и запускает основные сервисы (методы: `__init__`, `start`, `add_config_file`, `_register_core_services`).\n- **ControlPlaneService** — управляет каналами контроля и асинхронными операциями старта ", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", - "status": "passed", + "status": "failed", "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 1, + "repair": 4344 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** — инициализирует конфигурацию и запускает основные сервисы (методы: `__init__`, `start`, `add_config_file`, `_register_core_services`).\n- **ControlPlaneService** — управляет каналами контроля и асинхронными операциями старта ", + "repair_candidate": true }, "output": { - "passed": true, - "reasons": [], - "repair_used": false + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_relations", + "too_vague_for_architecture" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." } } ] @@ -166,7 +195,10 @@ "C0_SOURCE_CHUNKS" ], "retrieval_sufficient": true, - "answer_mode": "normal", + "answer_mode": "degraded", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -234,12 +266,46 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "ARCHITECTURE", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 8, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Компоненты, участвующие в подсистеме RuntimeManager:\n\n- **RuntimeManager** — инициализирует конфигурацию и запускает основные сервисы (методы: `__init__`, `start`, `add_config_file`, `_register_core_services`).\n- **ControlPlaneService** — управляет каналами контроля и асинхронными операциями старта ", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_relations", + "too_vague_for_architecture" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 155, - "pre_evidence_gate": 0, - "llm": 2995 + "router": 1, + "retrieval": 191, + "pre_evidence_gate": 1, + "llm": 6733, + "post_evidence_gate": 1, + "repair": 4344, + "post_evidence_gate_recheck": 1 } } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json similarity index 91% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json index e334c5c..befe75f 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Что делает функция create_runtime?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Функция `create_runtime` инициализирует и настраивает менеджер выполнения приложения.\n\n**Ключевые шаги:**\n1. Инициализация менеджера выполнения (`RuntimeManager()`).\n2. Добавление конфигурационного файла, если указан путь (`add_config_file`).\n3. Регистрация HTTP-канала управления, если включен режим управления (`register_channel`).\n4. Регистрация модуля приложения в менеджере выполнения (`register_module`).\n\n**Опорные файлы:**\n- `src/plba/bootstrap.py:8-29`\n\nЭтот процесс позволяет настроить и запустить приложение с учетом заданных конфигураций и режимов управления.", + "llm_answer": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если передан путь к конфигурационному файлу, вызывает `runtime.add_config_file(config_path)` для добавления конфигурации.\n- Если включён HTTP-контроль, регистрирует HTTP-канал управления через `runtime.control_plane.register_channel(HttpControlChannel(host=control_host, port=control_port, timeout=control_timeout))`.\n- Регистрирует модуль приложения методом `runtime.register_module(module)`.\n\nВозвращает сконфигурированный объект типа `RuntimeManager`.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -132,12 +132,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "create_runtime", "alternatives": [ - "create_runtime" + "create_runtime", + "create_runtime", + "annotations", + "json", + "Path" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1190,6 +1194,11 @@ "relations": [ { "path": "src/plba/bootstrap.py", + "start_line": 19, + "end_line": 19, + "edge_type": "calls", + "source": "create_runtime", + "target": "runtime.add_config_file", "metadata": { "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", "edge_type": "calls", @@ -1214,6 +1223,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 28, + "end_line": 28, + "edge_type": "reads_attr", + "source": "create_runtime", + "target": "runtime.register_module", "metadata": { "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", "edge_type": "reads_attr", @@ -1238,6 +1252,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 17, + "end_line": 17, + "edge_type": "instantiates", + "source": "create_runtime", + "target": "RuntimeManager", "metadata": { "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", "edge_type": "instantiates", @@ -1262,6 +1281,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 28, + "end_line": 28, + "edge_type": "calls", + "source": "create_runtime", + "target": "runtime.register_module", "metadata": { "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", "edge_type": "calls", @@ -1286,6 +1310,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 21, + "end_line": 27, + "edge_type": "calls", + "source": "create_runtime", + "target": "runtime.control_plane.register_channel", "metadata": { "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", "edge_type": "calls", @@ -1310,6 +1339,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 19, + "end_line": 19, + "edge_type": "reads_attr", + "source": "create_runtime", + "target": "runtime.add_config_file", "metadata": { "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", "edge_type": "reads_attr", @@ -1333,37 +1367,83 @@ "content": "create_runtime reads_attr runtime.add_config_file" } ], + "semantic_hints": [ + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" + }, + { + "path": "src/app_runtime/queue/in_memory.py", + "title": "InMemoryTaskQueue", + "symbol": "InMemoryTaskQueue", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)" + }, + { + "path": "src/app_runtime/config/file_loader.py", + "title": "ConfigFileLoader", + "symbol": "ConfigFileLoader", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)" + }, + { + "path": "src/app_runtime/workers/supervisor.py", + "title": "WorkerSupervisor", + "symbol": "WorkerSupervisor", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/workflow/engine/workflow_engine.py", + "title": "WorkflowEngine", + "symbol": "WorkflowEngine", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowEngine\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/tracing/store.py", + "title": "TraceContextStore", + "symbol": "TraceContextStore", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + } + ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1391,6 +1471,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1414,6 +1501,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2587,10 +2708,10 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 46, + "C1_SYMBOL_CATALOG": 43, "C0_SOURCE_CHUNKS": 20, - "C4_SEMANTIC_ROLES": 17, - "C2_DEPENDENCY_GRAPH": 69, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 47, "C3_ENTRYPOINTS": 13 } } @@ -2607,6 +2728,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2621,7 +2745,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2674,8 +2798,42 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 144, + "pre_evidence_gate": 1, + "llm": 4185, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -3774,6 +3932,154 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 144 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "create_runtime", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 43, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 47, + "C3_ENTRYPOINTS": 13 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4185 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md new file mode 100644 index 0000000..e4c0102 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-create-runtime.md @@ -0,0 +1,305 @@ +# plba-v2-explain-create-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Что делает функция create_runtime? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если передан путь к конфигурационному файлу, вызывает `runtime.add_config_file(config_path)` для добавления конфигурации.\n- Если включён HTTP-контроль, регистрирует HTTP-канал управления через `runtime.control_plane.register_channel(HttpControlChannel(host=control_host, port=control_port, timeout=control_timeout))`.\n- Регистрирует модуль приложения методом `runtime.register_module(module)`.\n\nВозвращает сконфигурированный объект типа `RuntimeManager`.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "create_runtime" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 144 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "create_runtime", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 43, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 47, + "C3_ENTRYPOINTS": 13 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4185 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Что делает функция create_runtime?", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Функция `create_runtime` определена в файле `src/plba/bootstrap.py`. Она создаёт и конфигурирует экземпляр `RuntimeManager`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP-канал управления.\n\nОсновные действия функции:\n- Создаёт экземпляр `RuntimeManager`.\n- Если переда" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 144, + "pre_evidence_gate": 1, + "llm": 4185, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json similarity index 89% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json index 6a5c7ed..493bbf0 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-local-http-channel", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 13, - "llm_answer": "Класс `HttpControlChannel` в файле `http_channel.py` реализует канал управления для HTTP-запросов. В конструкторе (`__init__`) создаются основные компоненты:\n\n- `_runner`: объект типа `UvicornThreadRunner`, управляющий асинхронным сервером uvicorn.\n- `_factory`: фабрика приложений типа `HttpControlAppFactory`, создающая приложения для обработки запросов.\n- `_actions`: коллекция действий управления, инициализируется как `None`.\n\nМетод `start` запускает сервер с приложением, созданным фабрикой, и ожидает завершения работы сервера при вызове `stop`. Класс предназначен для организации взаимодействия с внешним миром через HTTP-интерфейсы.", + "llm_answer": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фабрики и передавая коллбэки здоровья и действий. \nМетоды _health_response и _action_response (не полностью показаны) вероятно отвечают за обработчики API-эндпоинтов здоровья и выполнения действий. \nОстальные детали, такие как полный контекст методов или их реализации, отсутствуют в данном фрагменте.", "answer_mode": "answered", "path_scope": [ "src/app_runtime/control/http_channel.py" @@ -151,12 +151,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "HttpControlChannel", "alternatives": [ - "HttpControlChannel" + "ControlChannel", + "ControlActionSet", + "JSONResponse", + "HttpControlAppFactory", + "UvicornThreadRunner" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -738,6 +742,11 @@ "relations": [ { "path": "src/app_runtime/control/http_channel.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel._action_response", "metadata": { "edge_id": "c3ef21fcae96c82c00be74b3ab827d4af2085d89cb3fa5521c19a174aad84dbb", "edge_type": "dataflow_slice", @@ -778,6 +787,11 @@ }, { "path": "src/app_runtime/control/http_channel.py", + "start_line": 15, + "end_line": 22, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel.start", "metadata": { "edge_id": "51d73913df709152258ed1b9a8c8f4eb3c575eccfe6b982aef0b28e0789a29da", "edge_type": "dataflow_slice", @@ -818,6 +832,11 @@ }, { "path": "src/app_runtime/control/http_channel.py", + "start_line": 14, + "end_line": 34, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel._health_response", "metadata": { "edge_id": "f858f5c9e575f6c4cdfe3853571b7ee21d1f628a443541d2037c3dc9d0790bef", "edge_type": "dataflow_slice", @@ -858,6 +877,11 @@ }, { "path": "src/app_runtime/control/http_channel.py", + "start_line": 15, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "HttpControlChannel.__init__", + "target": "HttpControlChannel.stop", "metadata": { "edge_id": "0f827ef81a990258a8a74381c8564a8361afa6712dba3200592659c939adcb9d", "edge_type": "dataflow_slice", @@ -897,6 +921,7 @@ "content": "HttpControlChannel.__init__\n -> HttpControlChannel._runner\n -> HttpControlChannel.stop" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -1454,8 +1479,8 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 20, - "C0_SOURCE_CHUNKS": 16, + "C1_SYMBOL_CATALOG": 40, + "C0_SOURCE_CHUNKS": 17, "C2_DEPENDENCY_GRAPH": 18 } } @@ -1470,6 +1495,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -1484,7 +1512,7 @@ "C0_SOURCE_CHUNKS", "C2_DEPENDENCY_GRAPH" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -1525,8 +1553,44 @@ "failure_reasons": [], "evidence_count": 13 }, + "evidence_gate_input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 75, + "pre_evidence_gate": 1, + "llm": 3936, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -2028,6 +2092,146 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 75 + }, + "output": { + "rag_count": 13, + "answer_path_rag_count": 13, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlChannel", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C2_DEPENDENCY_GRAPH": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 12, + "C2_DEPENDENCY_GRAPH": 4 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 40, + "C0_SOURCE_CHUNKS": 17, + "C2_DEPENDENCY_GRAPH": 18 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 13 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3936 + }, + "output": { + "prompt_name": "code_qa_explain_local_answer", + "answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md new file mode 100644 index 0000000..56a2960 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-local-http-channel.md @@ -0,0 +1,285 @@ +# plba-v2-explain-local-http-channel + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 13, + "llm_answer": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фабрики и передавая коллбэки здоровья и действий. \nМетоды _health_response и _action_response (не полностью показаны) вероятно отвечают за обработчики API-эндпоинтов здоровья и выполнения действий. \nОстальные детали, такие как полный контекст методов или их реализации, отсутствуют в данном фрагменте.", + "answer_mode": "answered", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "symbol_candidates": [ + "HttpControlChannel" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN_LOCAL", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 75 + }, + "output": { + "rag_count": 13, + "answer_path_rag_count": 13, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlChannel", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C2_DEPENDENCY_GRAPH": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 12, + "C2_DEPENDENCY_GRAPH": 4 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 40, + "C0_SOURCE_CHUNKS": 17, + "C2_DEPENDENCY_GRAPH": 18 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 13 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3936 + }, + "output": { + "prompt_name": "code_qa_explain_local_answer", + "answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "HttpControlChannel", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN_LOCAL", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так?", + "sub_intent": "EXPLAIN_LOCAL", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C2_DEPENDENCY_GRAPH" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 4, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 13 + }, + "evidence_gate_input": { + "resolved_target": "HttpControlChannel", + "sub_intent": "EXPLAIN_LOCAL", + "target_type": "symbol", + "evidence_count": 13, + "code_chunk_count": 13, + "entrypoint_count": 0, + "relation_count": 4, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [ + "src/app_runtime/control/http_channel.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlChannel", + "draft_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Класс HttpControlChannel наследует ControlChannel и управляет HTTP-каналом контроля. \nИнициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI-приложения. \nМетод start запускает сервер с приложением, используя фа" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 75, + "pre_evidence_gate": 1, + "llm": 3936, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json similarity index 84% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json index 3b7279e..e802c17 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-nonexistent-symbol", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Объясни класс RuntimeFactoryManager", @@ -10,8 +10,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 0, - "llm_answer": "Сущность не удалось однозначно разрешить. Близкие варианты: ControlChannel, ControlChannel.stop, ControlActionSet.", - "answer_mode": "degraded", + "llm_answer": "Сущность RuntimeFactoryManager не найдена в доступном коде.", + "answer_mode": "not_found", "path_scope": [], "symbol_candidates": [ "RuntimeFactoryManager" @@ -24,10 +24,8 @@ "C3_ENTRYPOINTS" ] }, - "passed": false, - "mismatches": [ - "llm: expected answer to contain 'не найдена'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Объясни класс RuntimeFactoryManager", "router_result": { @@ -133,16 +131,10 @@ } }, "symbol_resolution": { - "status": "ambiguous", + "status": "not_found", "resolved_symbol": null, - "alternatives": [ - "ControlChannel", - "ControlChannel.stop", - "ControlActionSet", - "ControlChannel", - "ControlPlaneService" - ], - "confidence": 0.55 + "alternatives": [], + "confidence": 0.0 }, "evidence_policy": { "require_def": true, @@ -269,10 +261,11 @@ "retrieval_result": { "target_symbol_candidates": [], "resolved_symbol": null, - "symbol_resolution_status": "ambiguous", + "symbol_resolution_status": "not_found", "file_candidates": [], "code_chunks": [], "relations": [], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -359,11 +352,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 39, - "C0_SOURCE_CHUNKS": 20, - "C4_SEMANTIC_ROLES": 16, + "C1_SYMBOL_CATALOG": 75, + "C0_SOURCE_CHUNKS": 28, + "C4_SEMANTIC_ROLES": 23, "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 12 + "C3_ENTRYPOINTS": 18 } } }, @@ -379,6 +372,9 @@ ], "retrieval_sufficient": false, "answer_mode": "insufficient", + "resolved_target": null, + "answer_policy_branch": "explain_not_found", + "decision_reason": "symbol_resolution_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -393,7 +389,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "ambiguous" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -454,29 +450,50 @@ ], "evidence_count": 0 }, + "evidence_gate_input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "insufficient_evidence" ], "timings_ms": { - "router": 1, - "retrieval": 143, - "pre_evidence_gate": 0 + "router": 2, + "retrieval": 201, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } }, "rag_rows": [], "validation": { - "passed": false, - "action": "repair", - "reasons": [ - "degraded_answer_missing_guardrail" - ] + "passed": true, + "action": "return", + "reasons": [] }, "steps": [ { "step": "router", "status": "completed", "timings_ms": { - "router": 1 + "router": 2 }, "output": { "intent": "CODE_QA", @@ -489,12 +506,12 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 143 + "retrieval": 201 }, "output": { "rag_count": 33, "answer_path_rag_count": 0, - "resolved_symbol_status": "ambiguous", + "resolved_symbol_status": "not_found", "resolved_symbol": null, "requested_layers": [ "C1_SYMBOL_CATALOG", @@ -548,11 +565,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 39, - "C0_SOURCE_CHUNKS": 20, - "C4_SEMANTIC_ROLES": 16, + "C1_SYMBOL_CATALOG": 75, + "C0_SOURCE_CHUNKS": 28, + "C4_SEMANTIC_ROLES": 23, "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 12 + "C3_ENTRYPOINTS": 18 } } }, @@ -560,27 +577,53 @@ "step": "pre_evidence_gate", "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] }, "output": { "passed": false, "failure_reasons": [ "insufficient_evidence" ], - "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met)." + "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met).", + "evidence_count": 0 } }, { "step": "llm", "status": "skipped", + "timings_ms": { + "llm": 1 + }, "output": { "reason": "policy_short_circuit", - "answer_mode": "degraded" + "answer_mode": "not_found", + "decision_reason": "symbol_resolution_not_found", + "answer_policy_branch": "explain_not_found" } }, { "step": "post_evidence_gate", "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, "output": { "reason": "no_draft_answer" } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md similarity index 70% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md index ada6837..1784a91 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-nonexistent-symbol.md @@ -1,9 +1,9 @@ # plba-v2-explain-nonexistent-symbol -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml - runner: agent_runtime - mode: full_chain -- passed: False +- passed: True ## Query Объясни класс RuntimeFactoryManager @@ -15,8 +15,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 0, - "llm_answer": "Сущность не удалось однозначно разрешить. Близкие варианты: ControlChannel, ControlChannel.stop, ControlActionSet.", - "answer_mode": "degraded", + "llm_answer": "Сущность RuntimeFactoryManager не найдена в доступном коде.", + "answer_mode": "not_found", "path_scope": [], "symbol_candidates": [ "RuntimeFactoryManager" @@ -36,7 +36,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 1 + "router": 2 }, "output": { "intent": "CODE_QA", @@ -49,12 +49,12 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 143 + "retrieval": 201 }, "output": { "rag_count": 33, "answer_path_rag_count": 0, - "resolved_symbol_status": "ambiguous", + "resolved_symbol_status": "not_found", "resolved_symbol": null, "requested_layers": [ "C1_SYMBOL_CATALOG", @@ -108,11 +108,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 39, - "C0_SOURCE_CHUNKS": 20, - "C4_SEMANTIC_ROLES": 16, + "C1_SYMBOL_CATALOG": 75, + "C0_SOURCE_CHUNKS": 28, + "C4_SEMANTIC_ROLES": 23, "C2_DEPENDENCY_GRAPH": 55, - "C3_ENTRYPOINTS": 12 + "C3_ENTRYPOINTS": 18 } } }, @@ -120,27 +120,53 @@ "step": "pre_evidence_gate", "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] }, "output": { "passed": false, "failure_reasons": [ "insufficient_evidence" ], - "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met)." + "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met).", + "evidence_count": 0 } }, { "step": "llm", "status": "skipped", + "timings_ms": { + "llm": 1 + }, "output": { "reason": "policy_short_circuit", - "answer_mode": "degraded" + "answer_mode": "not_found", + "decision_reason": "symbol_resolution_not_found", + "answer_policy_branch": "explain_not_found" } }, { "step": "post_evidence_gate", "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, "output": { "reason": "no_draft_answer" } @@ -160,6 +186,9 @@ ], "retrieval_sufficient": false, "answer_mode": "insufficient", + "resolved_target": null, + "answer_policy_branch": "explain_not_found", + "decision_reason": "symbol_resolution_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -174,7 +203,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "ambiguous" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -235,15 +264,38 @@ ], "evidence_count": 0 }, + "evidence_gate_input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "insufficient_evidence" ], "timings_ms": { - "router": 1, - "retrieval": 143, - "pre_evidence_gate": 0 + "router": 2, + "retrieval": 201, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } } ## Mismatches -- llm: expected answer to contain 'не найдена' \ No newline at end of file +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json index 9d308c8..c12970a 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Объясни как работает класс RuntimeManager", @@ -10,8 +10,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "**Класс `RuntimeManager`** отвечает за управление жизненным циклом приложения и координацию различных компонентов системы.\n\n### Ключевые шаги работы класса:\n1. **Инициализация конфигурации:** \n Класс инициализирует начальные настройки приложения, включая загрузку конфигурационных файлов.\n \n2. **Регистрация каналов управления:**\n Метод `register_channel` позволяет зарегистрировать каналы управления, которые будут использоваться для взаимодействия с различными компонентами системы.\n\n3. **Запуск и остановка системы:**\n Методы `start` и `stop` инициируют запуск и остановку всех зарегистрированных каналов управления, обеспечивая корректное завершение работы системы.\n\n4. **Сохранение состояния:**\n Метод `snapshot` создает снимок текущего состояния системы, который может быть использован для восстановления или анализа состояния в будущем.\n\n### Опорные файлы:\n- `src/app_runtime/core/runtime.py`: Определение и реализация класса `RuntimeManager`.\n- `src/app_runtime/control/service.py`: Реализация методов регистрации и запуска каналов управления.\n- `src/app_runtime/control/http_channel.py`: Управление HTTP-каналом для взаимодействия с внешним миром.\n\nЭтот класс играет центральную роль в управлении потоком выполнения и состоянием приложения, координируя работу различных компонентов и обеспечивая их синхронность и согласованность.", - "answer_mode": "answered", + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager.", + "answer_mode": "degraded", "path_scope": [], "symbol_candidates": [ "RuntimeManager" @@ -131,12 +131,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1277,6 +1281,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1317,6 +1326,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1357,6 +1371,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1397,6 +1416,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1437,6 +1461,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1477,6 +1506,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1516,37 +1550,83 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/core/runtime.py", + "title": "RuntimeManager", + "symbol": "RuntimeManager", + "role": "pipeline_stage", + "confidence": 0.67, + "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1574,6 +1654,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1597,6 +1684,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2866,11 +2987,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 57, - "C0_SOURCE_CHUNKS": 15, - "C4_SEMANTIC_ROLES": 15, - "C2_DEPENDENCY_GRAPH": 54, - "C3_ENTRYPOINTS": 11 + "C1_SYMBOL_CATALOG": 64, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 57, + "C3_ENTRYPOINTS": 14 } } }, @@ -2885,7 +3006,10 @@ "C3_ENTRYPOINTS" ], "retrieval_sufficient": true, - "answer_mode": "normal", + "answer_mode": "degraded", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2900,7 +3024,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2953,8 +3077,48 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он играет роль стадии конвейера (pipeline stage), согласно семантическим подсказкам.\n\nОднако в предоставленном контексте отсутствуют конкретные методы, поля или вызовы этого класса. Если необходимы подробности работы `Runtim", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods", + "missing_concrete_calls", + "too_vague_for_explain" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 176, + "pre_evidence_gate": 1, + "llm": 3521, + "post_evidence_gate": 2, + "repair": 2383, + "post_evidence_gate_recheck": 2 + } }, "rag_rows": [ { @@ -4146,9 +4310,165 @@ } ], "validation": { - "passed": true, - "action": "return", - "reasons": [] - } + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods", + "missing_concrete_calls", + "too_vague_for_explain" + ] + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 176 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 64, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 57, + "C3_ENTRYPOINTS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3521 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он играет роль стадии конвейера (pipeline stage), согласно семантическим подсказкам.\n\nОднако в предоставленном контексте отсутствуют конкретные методы, поля или вызовы этого класса. Если необходимы подробности работы `Runtim", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 2, + "post_evidence_gate_recheck": 2, + "repair": 2383 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он играет роль стадии конвейера (pipeline stage), согласно семантическим подсказкам.\n\nОднако в предоставленном контексте отсутствуют конкретные методы, поля или вызовы этого класса. Если необходимы подробности работы `Runtim", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods", + "missing_concrete_calls", + "too_vague_for_explain" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md new file mode 100644 index 0000000..11eea7b --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md @@ -0,0 +1,315 @@ +# plba-v2-explain-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Объясни как работает класс RuntimeManager + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager.", + "answer_mode": "degraded", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 176 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 64, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 57, + "C3_ENTRYPOINTS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3521 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он играет роль стадии конвейера (pipeline stage), согласно семантическим подсказкам.\n\nОднако в предоставленном контексте отсутствуют конкретные методы, поля или вызовы этого класса. Если необходимы подробности работы `Runtim", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 2, + "post_evidence_gate_recheck": 2, + "repair": 2383 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он играет роль стадии конвейера (pipeline stage), согласно семантическим подсказкам.\n\nОднако в предоставленном контексте отсутствуют конкретные методы, поля или вызовы этого класса. Если необходимы подробности работы `Runtim", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods", + "missing_concrete_calls", + "too_vague_for_explain" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "degraded", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни как работает класс RuntimeManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Класс `RuntimeManager` определён в файле `src/app_runtime/core/runtime.py`. Он играет роль стадии конвейера (pipeline stage), согласно семантическим подсказкам.\n\nОднако в предоставленном контексте отсутствуют конкретные методы, поля или вызовы этого класса. Если необходимы подробности работы `Runtim", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods", + "missing_concrete_calls", + "too_vague_for_explain" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 176, + "pre_evidence_gate": 1, + "llm": 3521, + "post_evidence_gate": 2, + "repair": 2383, + "post_evidence_gate_recheck": 2 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json index e7d893b..9762165 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-explain-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Объясни как работает класс TraceService", @@ -10,8 +10,8 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 33, - "llm_answer": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Это сервис для управления контекстами трассировки и записи событий в журнал.\n\nЕго основные обязанности:\n- Инициализация сервиса при создании экземпляра (`__init__`) с передачей транспортов и хранилищ контекста.\n- Создание нового контекста трассировки через метод `create_context`, который генерирует уникальный идентификатор трассировки и сохраняет запись контекста в хранилище.\n- Предоставление текущего идентификатора трассировки через метод `current_trace_id`.\n\nКонструктор принимает два необязательных параметра:\n- `transport`: транспорт для отправки сообщений трассировки (по умолчанию используется `NoOpTraceTransport`).\n- `store`: хранилище контекста (по умолчанию используется `TraceContextStore`).\n\nТаким образом, `TraceService` играет ключевую роль в отслеживании и документировании событий приложения, обеспечивая единообразие логирования и мониторинга.", - "answer_mode": "answered", + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по TraceService.", + "answer_mode": "degraded", "path_scope": [], "symbol_candidates": [ "TraceService" @@ -131,12 +131,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "TraceService", "alternatives": [ + "TraceService", + "TraceService", + "TraceService", + "TraceService", "TraceService" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1280,6 +1284,11 @@ "relations": [ { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 61, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.create_context", "metadata": { "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", "edge_type": "dataflow_slice", @@ -1320,6 +1329,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 84, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.close_context", "metadata": { "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", "edge_type": "dataflow_slice", @@ -1360,6 +1374,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 78, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.open_context", "metadata": { "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", "edge_type": "dataflow_slice", @@ -1400,6 +1419,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 41, + "end_line": 43, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.__init__", "metadata": { "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", "edge_type": "dataflow_slice", @@ -1440,6 +1464,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 81, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.current_trace_id", "metadata": { "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", "edge_type": "dataflow_slice", @@ -1480,6 +1509,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 88, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.step", "metadata": { "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", "edge_type": "dataflow_slice", @@ -1519,37 +1553,83 @@ "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step" } ], + "semantic_hints": [ + { + "path": "src/app_runtime/tracing/service.py", + "title": "TraceService", + "symbol": "TraceService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "TraceService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (13)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" + }, + { + "path": "src/app_runtime/queue/in_memory.py", + "title": "InMemoryTaskQueue", + "symbol": "InMemoryTaskQueue", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "InMemoryTaskQueue\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (9)" + }, + { + "path": "src/app_runtime/config/file_loader.py", + "title": "ConfigFileLoader", + "symbol": "ConfigFileLoader", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "ConfigFileLoader\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (8)" + }, + { + "path": "src/app_runtime/tracing/store.py", + "title": "TraceContextStore", + "symbol": "TraceContextStore", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "TraceContextStore\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + }, + { + "path": "src/app_runtime/workers/supervisor.py", + "title": "WorkerSupervisor", + "symbol": "WorkerSupervisor", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkerSupervisor\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (6)" + } + ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1577,6 +1657,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1600,6 +1687,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "", + "handler_symbol": "", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -2869,11 +2990,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 35, - "C0_SOURCE_CHUNKS": 12, - "C4_SEMANTIC_ROLES": 12, - "C2_DEPENDENCY_GRAPH": 42, - "C3_ENTRYPOINTS": 10 + "C1_SYMBOL_CATALOG": 49, + "C0_SOURCE_CHUNKS": 22, + "C4_SEMANTIC_ROLES": 21, + "C2_DEPENDENCY_GRAPH": 49, + "C3_ENTRYPOINTS": 15 } } }, @@ -2888,7 +3009,10 @@ "C3_ENTRYPOINTS" ], "retrieval_sufficient": true, - "answer_mode": "normal", + "answer_mode": "degraded", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2903,7 +3027,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2956,8 +3080,46 @@ "failure_reasons": [], "evidence_count": 33 }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory` и используется для управления трассировкой приложений.\n\nОсновные компоненты:\n- **Конструктор**: принимает опциональные аргументы `transport` и `store`. Если они не указаны, используются", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по TraceService." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 158, + "pre_evidence_gate": 1, + "llm": 4974, + "post_evidence_gate": 3, + "repair": 4719, + "post_evidence_gate_recheck": 2 + } }, "rag_rows": [ { @@ -4149,9 +4311,161 @@ } ], "validation": { - "passed": true, - "action": "return", - "reasons": [] - } + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ] + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 158 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "TraceService", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 49, + "C0_SOURCE_CHUNKS": 22, + "C4_SEMANTIC_ROLES": 21, + "C2_DEPENDENCY_GRAPH": 49, + "C3_ENTRYPOINTS": 15 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4974 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory` и используется для управления трассировкой приложений.\n\nОсновные компоненты:\n- **Конструктор**: принимает опциональные аргументы `transport` и `store`. Если они не указаны, используются", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 3, + "post_evidence_gate_recheck": 2, + "repair": 4719 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory` и используется для управления трассировкой приложений.\n\nОсновные компоненты:\n- **Конструктор**: принимает опциональные аргументы `transport` и `store`. Если они не указаны, используются", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по TraceService." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md new file mode 100644 index 0000000..c5d90a9 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-explain-trace-service.md @@ -0,0 +1,311 @@ +# plba-v2-explain-trace-service + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Объясни как работает класс TraceService + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 33, + "llm_answer": "Недостаточно подтверждённых данных для уверенного ответа по TraceService.", + "answer_mode": "degraded", + "path_scope": [], + "symbol_candidates": [ + "TraceService" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 158 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 33, + "resolved_symbol_status": "resolved", + "resolved_symbol": "TraceService", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 49, + "C0_SOURCE_CHUNKS": 22, + "C4_SEMANTIC_ROLES": 21, + "C2_DEPENDENCY_GRAPH": 49, + "C3_ENTRYPOINTS": 15 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 33 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4974 + }, + "output": { + "prompt_name": "code_qa_explain_answer", + "answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory` и используется для управления трассировкой приложений.\n\nОсновные компоненты:\n- **Конструктор**: принимает опциональные аргументы `transport` и `store`. Если они не указаны, используются", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "failed", + "timings_ms": { + "post_evidence_gate": 3, + "post_evidence_gate_recheck": 2, + "repair": 4719 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory` и используется для управления трассировкой приложений.\n\nОсновные компоненты:\n- **Конструктор**: принимает опциональные аргументы `transport` и `store`. Если они не указаны, используются", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по TraceService." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "degraded", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни как работает класс TraceService", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 33 + }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "EXPLAIN", + "target_type": "symbol", + "evidence_count": 33, + "code_chunk_count": 33, + "entrypoint_count": 3, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Класс `TraceService` находится в файле `src/app_runtime/tracing/service.py`. Он наследует от `TraceContextFactory` и используется для управления трассировкой приложений.\n\nОсновные компоненты:\n- **Конструктор**: принимает опциональные аргументы `transport` и `store`. Если они не указаны, используются", + "repair_candidate": true + }, + "output": { + "passed": false, + "action": "repair", + "reasons": [ + "missing_concrete_methods" + ], + "repair_used": true, + "final_answer_preview": "Недостаточно подтверждённых данных для уверенного ответа по TraceService." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 158, + "pre_evidence_gate": 1, + "llm": 4974, + "post_evidence_gate": 3, + "repair": 4719, + "post_evidence_gate_recheck": 2 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json similarity index 90% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json index 3a05ed5..504529c 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-entrypoints-control-plane", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Найди точки входа HTTP control plane", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 9, - "llm_answer": "Подтверждённые HTTP route points:\n\n- GET /health (src/app_runtime/control/http_app.py:51)\n- POST (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n- GET (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n\nЭти маршруты объявлены непосредственно в src/app_runtime/control/http_app.py.", + "llm_answer": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n\nКандидаты на входные точки отсутствуют.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -519,37 +519,18 @@ } ], "relations": [], + "semantic_hints": [], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -577,6 +558,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -600,6 +588,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -918,18 +940,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -937,9 +961,16 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 16 - } + "C3_ENTRYPOINTS": 14, + "C0_SOURCE_CHUNKS": 11 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Найди точки входа HTTP control plane", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, "diagnostics": { @@ -951,6 +982,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -994,12 +1028,41 @@ "failure_reasons": [], "evidence_count": 9 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 29, - "pre_evidence_gate": 0, - "llm": 853 + "router": 1, + "retrieval": 35, + "pre_evidence_gate": 1, + "llm": 3053, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -1305,7 +1368,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -1318,7 +1381,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 29 + "retrieval": 35 }, "output": { "rag_count": 9, @@ -1337,18 +1400,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -1356,45 +1421,78 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 16 - } + "C3_ENTRYPOINTS": 14, + "C0_SOURCE_CHUNKS": 11 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Найди точки входа HTTP control plane", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, { "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 9 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 853 + "llm": 3053 }, "output": { "prompt_name": "code_qa_find_entrypoints_answer", - "answer_preview": "Подтверждённые HTTP route points:\n\n- GET /health (src/app_runtime/control/http_app.py:51)\n- POST (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n- GET (не указан путь, только декорированный метод в src/app_runtime/control/http_app.py:38-42)\n\nЭти маршруты объ" + "answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md new file mode 100644 index 0000000..25fe93d --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-control-plane.md @@ -0,0 +1,262 @@ +# plba-v2-find-entrypoints-control-plane + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Найди точки входа HTTP control plane + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 9, + "llm_answer": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n\nКандидаты на входные точки отсутствуют.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "HTTP", + "control", + "plane" + ], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 35 + }, + "output": { + "rag_count": 9, + "answer_path_rag_count": 9, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 14, + "C0_SOURCE_CHUNKS": 11 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Найди точки входа HTTP control plane", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 9 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3053 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Найди точки входа HTTP control plane", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 6, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 9 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 9, + "code_chunk_count": 9, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённые HTTP routes:\n\n1. GET /health — обработчик `health`, объявлен в `src/app_runtime/control/http_app.py`:31-34.\n2. GET /actions/{action} — обработчик `action`, объявлен в `src/app_runtime/control/http_app.py`:38-42.\n3. POST /actions/{action} — обработчик `action`, объявлен в `src/app_runt" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 35, + "pre_evidence_gate": 1, + "llm": 3053, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json similarity index 75% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json index 38d9ece..599a802 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-entrypoints-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где health endpoint?", @@ -9,8 +9,8 @@ "sub_intent": "FIND_ENTRYPOINTS", "graph_id": "CodeQAGraph", "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "Конкретный health endpoint не обнаружен напрямую.\n\nОднако подтверждённые HTTP routes:\n- GET / (объявлен в src/app_runtime/control/http_app.py:31-34)\n- POST / (объявлен в src/app_runtime/control/http_app.py:38-42)\n- GET / (повторное объявление в src/app_runtime/control/http_app.py:38-42)", + "rag_count": 10, + "llm_answer": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -22,10 +22,8 @@ "C0_SOURCE_CHUNKS" ] }, - "passed": false, - "mismatches": [ - "llm: expected answer to contain 'GET /health'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Где health endpoint?", "router_result": { @@ -122,12 +120,9 @@ } }, "symbol_resolution": { - "status": "pending", + "status": "not_found", "resolved_symbol": null, - "alternatives": [ - "health", - "endpoint" - ], + "alternatives": [], "confidence": 0.0 }, "evidence_policy": { @@ -491,28 +486,22 @@ "last_modified": null, "staleness_score": null } - } - ], - "relations": [], - "entrypoints": [ + }, { + "layer": "C0_SOURCE_CHUNKS", "path": "src/app_runtime/control/http_app.py", - "title": "app.post", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "start_line": 15, + "end_line": 53, "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", "repo_id": "plba", + "artifact_type": null, "section": null, "doc_id": null, "doc_version": null, @@ -521,10 +510,21 @@ "last_modified": null, "staleness_score": null } - }, + } + ], + "relations": [], + "semantic_hints": [], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -552,6 +552,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -575,6 +582,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -587,7 +628,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -884,6 +925,36 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "retrieval_report": { @@ -893,18 +964,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -912,9 +985,16 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 37, - "C0_SOURCE_CHUNKS": 24 - } + "C3_ENTRYPOINTS": 64, + "C0_SOURCE_CHUNKS": 17 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, "diagnostics": { @@ -926,6 +1006,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -937,7 +1020,7 @@ "C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -958,7 +1041,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -967,10 +1050,44 @@ "evidence_gate_decision": { "sufficient": true, "failure_reasons": [], - "evidence_count": 9 + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 96, + "pre_evidence_gate": 1, + "llm": 1485, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -1263,12 +1380,175 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "validation": { "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 96 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 64, + "C0_SOURCE_CHUNKS": 17 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1485 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md new file mode 100644 index 0000000..bde801c --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.md @@ -0,0 +1,261 @@ +# plba-v2-find-entrypoints-health-endpoint + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где health endpoint? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 10, + "llm_answer": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "health", + "endpoint" + ], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 96 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 64, + "C0_SOURCE_CHUNKS": 17 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1485 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где health endpoint?", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 7, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Подтверждённая точка входа для health endpoint:\nGET /health, declared in src/app_runtime/control/http_app.py, lines 31-34, handler function named 'health'." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 96, + "pre_evidence_gate": 1, + "llm": 1485, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json index 63cdab9..14ed8eb 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-create-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для create_runtime?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "- tests/test_runtime.py:342-405 (test_public_plba_package_exports_runtime_builder_and_worker_contract)", + "llm_answer": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -136,12 +136,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "create_runtime", "alternatives": [ - "create_runtime" + "create_runtime", + "create_runtime", + "FileConfigProvider", + "hashlib", + "json" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -923,6 +927,11 @@ "relations": [ { "path": "src/plba/bootstrap.py", + "start_line": 19, + "end_line": 19, + "edge_type": "calls", + "source": "create_runtime", + "target": "runtime.add_config_file", "metadata": { "edge_id": "4eaeec4ac55a59d5f66fd01c4754955f8fedaf4bc3df13fa769b352c7bfaacbb", "edge_type": "calls", @@ -947,6 +956,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 28, + "end_line": 28, + "edge_type": "reads_attr", + "source": "create_runtime", + "target": "runtime.register_module", "metadata": { "edge_id": "45516c79ff358dbf9b650a081668df0f66d2fe989300f985a1a78be6be166f8f", "edge_type": "reads_attr", @@ -971,6 +985,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 17, + "end_line": 17, + "edge_type": "instantiates", + "source": "create_runtime", + "target": "RuntimeManager", "metadata": { "edge_id": "0adba17984f850ea1608c9e734d2dd5c325cfde3a8133123aa239e44935ad18e", "edge_type": "instantiates", @@ -995,6 +1014,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 28, + "end_line": 28, + "edge_type": "calls", + "source": "create_runtime", + "target": "runtime.register_module", "metadata": { "edge_id": "ab6003c3441addc1ba1b81edeca009165559f652f6b2cf424e5ae61b1f617de8", "edge_type": "calls", @@ -1019,6 +1043,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 21, + "end_line": 27, + "edge_type": "calls", + "source": "create_runtime", + "target": "runtime.control_plane.register_channel", "metadata": { "edge_id": "2678250030b9ce47a3b3b55fac7897ac530367edc8374ac9d5e6ecafb1e483f0", "edge_type": "calls", @@ -1043,6 +1072,11 @@ }, { "path": "src/plba/bootstrap.py", + "start_line": 19, + "end_line": 19, + "edge_type": "reads_attr", + "source": "create_runtime", + "target": "runtime.add_config_file", "metadata": { "edge_id": "30d4e8aae984ab84d523e80d02f1caeda52d547fa3d2aa47be8845931cabbca2", "edge_type": "reads_attr", @@ -1066,6 +1100,7 @@ "content": "create_runtime reads_attr runtime.add_config_file" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [ { @@ -1897,8 +1932,8 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 33, - "C2_DEPENDENCY_GRAPH": 42, + "C1_SYMBOL_CATALOG": 28, + "C2_DEPENDENCY_GRAPH": 34, "C0_SOURCE_CHUNKS": 14 } } @@ -1913,6 +1948,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -1925,7 +1963,7 @@ "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -1964,8 +2002,42 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 77, + "pre_evidence_gate": 1, + "llm": 1934, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -2741,6 +2813,138 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 77 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "create_runtime", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 28, + "C2_DEPENDENCY_GRAPH": 34, + "C0_SOURCE_CHUNKS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1934 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md new file mode 100644 index 0000000..88c61e4 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-create-runtime.md @@ -0,0 +1,269 @@ +# plba-v2-find-tests-create-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для create_runtime? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "create_runtime" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 77 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "create_runtime", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 28, + "C2_DEPENDENCY_GRAPH": 34, + "C0_SOURCE_CHUNKS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1934 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "create_runtime", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для create_runtime?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "create_runtime", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 1, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "create_runtime", + "draft_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `create_runtime` не найдены.\n\nБлижайший косвенный тест:\n- `tests/test_runtime.py::test_public_plba_package_exports_runtime_builder_and_worker_contract`\n - Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 77, + "pre_evidence_gate": 1, + "llm": 1934, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json similarity index 94% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json index 546bf32..2ba332b 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-runtime-manager", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для RuntimeManager?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "Прямые тесты для `RuntimeManager` обнаружены в следующих файлах:\n\n- **tests/test_runtime.py**: проверка инициализации и поведения `RuntimeManager`.\n- **tests/test_business_control_actions.py**: хотя этот файл упоминает `RuntimeManager`, он непосредственно не предназначен для тестирования `RuntimeManager`. Вместо этого здесь проверяются контрольные каналы и бизнес-действия.\n\nКосвенных тестов, специфичных для `RuntimeManager`, не найдено.", + "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -136,12 +136,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1017,6 +1021,11 @@ "relations": [ { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1057,6 +1066,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1097,6 +1111,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1137,6 +1156,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1177,6 +1201,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1217,6 +1246,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1256,6 +1290,7 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.configuration\n -> RuntimeManager.add_config_file" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [ { @@ -2188,9 +2223,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 41, - "C2_DEPENDENCY_GRAPH": 61, - "C0_SOURCE_CHUNKS": 15 + "C1_SYMBOL_CATALOG": 48, + "C2_DEPENDENCY_GRAPH": 60, + "C0_SOURCE_CHUNKS": 21 } } }, @@ -2204,6 +2239,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2216,7 +2254,7 @@ "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2255,8 +2293,42 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 2, + "retrieval": 130, + "pre_evidence_gate": 1, + "llm": 1947, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -3128,6 +3200,138 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 130 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 48, + "C2_DEPENDENCY_GRAPH": 60, + "C0_SOURCE_CHUNKS": 21 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1947 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md new file mode 100644 index 0000000..3cd0b95 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md @@ -0,0 +1,269 @@ +# plba-v2-find-tests-runtime-manager + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для RuntimeManager? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 130 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 48, + "C2_DEPENDENCY_GRAPH": 60, + "C0_SOURCE_CHUNKS": 21 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 1947 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для RuntimeManager?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 2, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`.", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`.\n\nКосвенные тесты:\n- В файле `tests/test_business_control_actions.py` есть тесты, использующие компоненты контроля, которые взаимодействуют с `RuntimeManager`." + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 2, + "retrieval": 130, + "pre_evidence_gate": 1, + "llm": 1947, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json similarity index 94% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json index b6879ec..e4d2029 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-trace-service", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для TraceService?", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "Прямые тесты для `TraceService` находятся в файле `tests/test_runtime.py`.\n\nВ следующих функциях проверяются различные аспекты работы `TraceService`:\n- `test_trace_service_allows_messages_without_status`: проверяет корректность записи сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверяет поддержку различных уровней логирования.", + "llm_answer": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверяет поддержку уровней debug, warning и error.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -136,12 +136,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "TraceService", "alternatives": [ + "TraceService", + "TraceService", + "TraceService", + "TraceService", "TraceService" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1013,6 +1017,11 @@ "relations": [ { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 61, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.create_context", "metadata": { "edge_id": "3b052062067a78aef3302ee1d996897e02a67d1b340397bea4f59fe147c0492a", "edge_type": "dataflow_slice", @@ -1053,6 +1062,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 84, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.close_context", "metadata": { "edge_id": "7a9353ef57c9ae5d19b3a0c6ac50fad05e6d21d31bbe1cd1cd07af6332ba6505", "edge_type": "dataflow_slice", @@ -1093,6 +1107,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 78, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.open_context", "metadata": { "edge_id": "a6e13b9ebc4fed84586afd53ed92a4d14757e440873f572b2337d5622ee96031", "edge_type": "dataflow_slice", @@ -1133,6 +1152,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 41, + "end_line": 43, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.__init__", "metadata": { "edge_id": "1e923a93faa05c3c43ca9b19bd047007a8589ccce57d3cc1798ae7f9f200af98", "edge_type": "dataflow_slice", @@ -1173,6 +1197,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 81, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.current_trace_id", "metadata": { "edge_id": "3ea17138634b1190bded77ddb84aa1595124f6519b246f24fc4b02bd62b5cac1", "edge_type": "dataflow_slice", @@ -1213,6 +1242,11 @@ }, { "path": "src/app_runtime/tracing/service.py", + "start_line": 42, + "end_line": 88, + "edge_type": "dataflow_slice", + "source": "TraceService.__init__", + "target": "TraceService.step", "metadata": { "edge_id": "9f34c5da9b09fba99df6f6b1bde183a9aeb45111b8218a747c71590c2c9f60f2", "edge_type": "dataflow_slice", @@ -1252,6 +1286,7 @@ "content": "TraceService.__init__\n -> TraceService.store\n -> TraceService.step" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [ { @@ -2189,9 +2224,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 32, - "C2_DEPENDENCY_GRAPH": 34, - "C0_SOURCE_CHUNKS": 14 + "C1_SYMBOL_CATALOG": 34, + "C2_DEPENDENCY_GRAPH": 38, + "C0_SOURCE_CHUNKS": 16 } } }, @@ -2205,6 +2240,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2217,7 +2255,7 @@ "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2256,8 +2294,42 @@ "failure_reasons": [], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 90, + "pre_evidence_gate": 1, + "llm": 2378, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -3129,6 +3201,138 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 90 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "TraceService", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 34, + "C2_DEPENDENCY_GRAPH": 38, + "C0_SOURCE_CHUNKS": 16 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 2378 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md new file mode 100644 index 0000000..efd65ba --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-trace-service.md @@ -0,0 +1,269 @@ +# plba-v2-find-tests-trace-service + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где тесты для TraceService? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 24, + "llm_answer": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_supports_debug_warning_and_error_levels`: проверяет поддержку уровней debug, warning и error.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "TraceService" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 90 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "TraceService", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 34, + "C2_DEPENDENCY_GRAPH": 38, + "C0_SOURCE_CHUNKS": 16 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 2378 + }, + "output": { + "prompt_name": "code_qa_find_tests_answer", + "answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "TraceService", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где тесты для TraceService?", + "sub_intent": "FIND_TESTS", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 6, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 10, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 24 + }, + "evidence_gate_input": { + "resolved_target": "TraceService", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 3, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "TraceService", + "draft_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Прямые тесты для TraceService находятся в файле `tests/test_runtime.py`:\n\n- `test_trace_service_allows_messages_without_status`: проверяет возможность отправки сообщений без статуса.\n- `test_trace_service_writes_contexts_and_messages`: проверяет запись контекстов и сообщений.\n- `test_trace_service_s" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 90, + "pre_evidence_gate": 1, + "llm": 2378, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json similarity index 95% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json index 7fa9a08..6ad444f 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-tests-workflow-runtime-factory-negative", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где тесты для WorkflowRuntimeFactory?", @@ -136,12 +136,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "WorkflowRuntimeFactory", "alternatives": [ - "WorkflowRuntimeFactory" + "WorkflowRuntimeFactory", + "WorkflowRuntimeFactory", + "WorkflowRuntimeFactory", + "WorkflowRuntimeFactory.__init__", + "WorkflowRuntimeFactory.create_engine" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -986,6 +990,11 @@ "relations": [ { "path": "src/app_runtime/workflow/runtime_factory.py", + "start_line": 11, + "end_line": 19, + "edge_type": "dataflow_slice", + "source": "WorkflowRuntimeFactory.__init__", + "target": "WorkflowRuntimeFactory.create_engine", "metadata": { "edge_id": "db6124c75b447e4a0a9ba267bd6d6cdf267b41a733b2843d724dd42ec6f4945d", "edge_type": "dataflow_slice", @@ -1026,6 +1035,11 @@ }, { "path": "src/app_runtime/workflow/runtime_factory.py", + "start_line": 12, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "WorkflowRuntimeFactory.__init__", + "target": "WorkflowRuntimeFactory.create_engine", "metadata": { "edge_id": "f46f5a871a3800b517b0f94ed2551392629e1d7920bc3e3b5a21e0d8f012b741", "edge_type": "dataflow_slice", @@ -1066,6 +1080,11 @@ }, { "path": "src/app_runtime/workflow/runtime_factory.py", + "start_line": 9, + "end_line": 16, + "edge_type": "dataflow_slice", + "source": "WorkflowRuntimeFactory.__init__", + "target": "WorkflowRuntimeFactory.create_engine", "metadata": { "edge_id": "543624853400c556d1939007017145281d76b00a694c7d5c4fbb0414ded3434e", "edge_type": "dataflow_slice", @@ -1106,6 +1125,11 @@ }, { "path": "src/app_runtime/workflow/runtime_factory.py", + "start_line": 10, + "end_line": 19, + "edge_type": "dataflow_slice", + "source": "WorkflowRuntimeFactory.__init__", + "target": "WorkflowRuntimeFactory.create_engine", "metadata": { "edge_id": "346cf5ddb4308b8403d27c5b54da8cba298bb0af7dc04c2fe30312ef574103c6", "edge_type": "dataflow_slice", @@ -1146,6 +1170,11 @@ }, { "path": "src/app_runtime/workflow/runtime_factory.py", + "start_line": 12, + "end_line": 12, + "edge_type": "writes_attr", + "source": "WorkflowRuntimeFactory.__init__", + "target": "WorkflowRuntimeFactory._snapshot_sanitizer", "metadata": { "edge_id": "de0cb1913ba41f673cfb601cab23cfb2e1044ed3dd8c061aff486075aeb8af20", "edge_type": "writes_attr", @@ -1170,6 +1199,11 @@ }, { "path": "src/app_runtime/workflow/runtime_factory.py", + "start_line": 15, + "end_line": 18, + "edge_type": "calls", + "source": "WorkflowRuntimeFactory.create_engine", + "target": "WorkflowPersistence.create_default", "metadata": { "edge_id": "fa86efb6871092fc88df68295c0d92dbe46253e1afa3246ca62b6da11d4d5569", "edge_type": "calls", @@ -1193,6 +1227,7 @@ "content": "WorkflowRuntimeFactory.create_engine calls WorkflowPersistence.create_default" } ], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -2082,9 +2117,9 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 24, - "C2_DEPENDENCY_GRAPH": 27, - "C0_SOURCE_CHUNKS": 12 + "C1_SYMBOL_CATALOG": 31, + "C2_DEPENDENCY_GRAPH": 43, + "C0_SOURCE_CHUNKS": 16 } } }, @@ -2098,6 +2133,9 @@ ], "retrieval_sufficient": false, "answer_mode": "degraded", + "resolved_target": "WorkflowRuntimeFactory", + "answer_policy_branch": "evidence_gate_short_circuit", + "decision_reason": "tests_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -2110,7 +2148,7 @@ "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -2151,10 +2189,37 @@ ], "evidence_count": 24 }, + "evidence_gate_input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "tests_not_found" ], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 91, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -2996,6 +3061,131 @@ "reasons": [ "degraded_answer_missing_guardrail" ] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_TESTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 91 + }, + "output": { + "rag_count": 24, + "answer_path_rag_count": 24, + "resolved_symbol_status": "resolved", + "resolved_symbol": "WorkflowRuntimeFactory", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C2_DEPENDENCY_GRAPH", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C0_SOURCE_CHUNKS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C0_SOURCE_CHUNKS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 31, + "C2_DEPENDENCY_GRAPH": 43, + "C0_SOURCE_CHUNKS": 16 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": false, + "failure_reasons": [ + "tests_not_found" + ], + "degraded_message": "Insufficient evidence for a confident answer. No test candidates found.", + "evidence_count": 24 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "degraded", + "decision_reason": "tests_not_found", + "answer_policy_branch": "evidence_gate_short_circuit" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, + "output": { + "reason": "no_draft_answer" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md similarity index 57% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md index 81f0f7b..aa1031c 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-find-tests-runtime-manager.md +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-find-tests-workflow-runtime-factory-negative.md @@ -1,12 +1,12 @@ -# plba-v2-find-tests-runtime-manager +# plba-v2-find-tests-workflow-runtime-factory-negative -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml - runner: agent_runtime - mode: full_chain - passed: True ## Query -Где тесты для RuntimeManager? +Где тесты для WorkflowRuntimeFactory? ## Actual { @@ -15,11 +15,11 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 24, - "llm_answer": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`. Эти тесты проверяют инициализацию и поведение объекта `RuntimeManager`.\n\nКосвенных тестов, явно связанных с `RuntimeManager`, больше нигде не обнаружено.", - "answer_mode": "answered", + "llm_answer": "Insufficient evidence for a confident answer. No test candidates found.", + "answer_mode": "degraded", "path_scope": [], "symbol_candidates": [ - "RuntimeManager" + "WorkflowRuntimeFactory" ], "layers": [ "C1_SYMBOL_CATALOG", @@ -47,13 +47,13 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 141 + "retrieval": 91 }, "output": { "rag_count": 24, "answer_path_rag_count": 24, "resolved_symbol_status": "resolved", - "resolved_symbol": "RuntimeManager", + "resolved_symbol": "WorkflowRuntimeFactory", "requested_layers": [ "C1_SYMBOL_CATALOG", "C2_DEPENDENCY_GRAPH", @@ -92,46 +92,65 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 58, - "C2_DEPENDENCY_GRAPH": 58, - "C0_SOURCE_CHUNKS": 24 + "C1_SYMBOL_CATALOG": 31, + "C2_DEPENDENCY_GRAPH": 43, + "C0_SOURCE_CHUNKS": 16 } } }, { "step": "pre_evidence_gate", - "status": "passed", + "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] }, "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" + "passed": false, + "failure_reasons": [ + "tests_not_found" + ], + "degraded_message": "Insufficient evidence for a confident answer. No test candidates found.", + "evidence_count": 24 } }, { "step": "llm", - "status": "completed", + "status": "skipped", "timings_ms": { - "llm": 584 + "llm": 1 }, "output": { - "prompt_name": "code_qa_find_tests_answer", - "answer_preview": "Прямые тесты для `RuntimeManager` находятся в файле `tests/test_runtime.py`. Эти тесты проверяют инициализацию и поведение объекта `RuntimeManager`.\n\nКосвенных тестов, явно связанных с `RuntimeManager`, больше нигде не обнаружено." + "reason": "policy_short_circuit", + "answer_mode": "degraded", + "decision_reason": "tests_not_found", + "answer_policy_branch": "evidence_gate_short_circuit" } }, { "step": "post_evidence_gate", - "status": "passed", + "status": "skipped", "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" }, "output": { - "passed": true, - "reasons": [], - "repair_used": false + "reason": "no_draft_answer" } } ] @@ -145,8 +164,11 @@ "C2_DEPENDENCY_GRAPH", "C0_SOURCE_CHUNKS" ], - "retrieval_sufficient": true, - "answer_mode": "normal", + "retrieval_sufficient": false, + "answer_mode": "degraded", + "resolved_target": "WorkflowRuntimeFactory", + "answer_policy_branch": "evidence_gate_short_circuit", + "decision_reason": "tests_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -163,7 +185,7 @@ }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Где тесты для RuntimeManager?", + "query": "Где тесты для WorkflowRuntimeFactory?", "sub_intent": "FIND_TESTS", "path_scope": [], "requested_layers": [ @@ -194,16 +216,42 @@ ], "empty_layers": [], "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], + "sufficient": false, + "failure_reasons": [ + "tests_not_found" + ], "evidence_count": 24 }, - "failure_reasons": [], + "evidence_gate_input": { + "resolved_target": "WorkflowRuntimeFactory", + "sub_intent": "FIND_TESTS", + "target_type": "symbol", + "evidence_count": 24, + "code_chunk_count": 24, + "entrypoint_count": 0, + "relation_count": 6, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "degraded", + "draft_present": false, + "resolved_target": "WorkflowRuntimeFactory" + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "tests_not_found" + ], "timings_ms": { "router": 1, - "retrieval": 141, - "pre_evidence_gate": 0, - "llm": 584 + "retrieval": 91, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json similarity index 65% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json index aea7b21..e84eb84 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162307/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-nonexistent", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/app_runtime/core/missing_runtime.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 0, - "llm_answer": "Файл `src/app_runtime/core/missing_runtime.py` не найден.", + "llm_answer": "Файл src/app_runtime/core/missing_runtime.py не найден.", "answer_mode": "not_found", "path_scope": [ "src/app_runtime/core/missing_runtime.py" @@ -20,11 +20,8 @@ "C0_SOURCE_CHUNKS" ] }, - "passed": false, - "mismatches": [ - "answer_mode: expected degraded, got not_found", - "llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Открой файл src/app_runtime/core/missing_runtime.py", "router_result": { @@ -226,6 +223,7 @@ "file_candidates": [], "code_chunks": [], "relations": [], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -269,7 +267,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 23 + "C0_SOURCE_CHUNKS": 14 } } }, @@ -281,6 +279,9 @@ ], "retrieval_sufficient": false, "answer_mode": "insufficient", + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "answer_policy_branch": "open_file_not_found", + "decision_reason": "path_scope_empty", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -325,17 +326,167 @@ ], "evidence_count": 0 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "path_scope_empty", "layer_c0_empty" ], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 15, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } }, "rag_rows": [], "validation": { "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 15 + }, + "output": { + "rag_count": 0, + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/missing_runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "output": { + "passed": false, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved.", + "evidence_count": 0 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "path_scope_empty", + "answer_policy_branch": "open_file_not_found" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md new file mode 100644 index 0000000..8f60590 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.md @@ -0,0 +1,245 @@ +# plba-v2-open-file-nonexistent + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/app_runtime/core/missing_runtime.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 0, + "llm_answer": "Файл src/app_runtime/core/missing_runtime.py не найден.", + "answer_mode": "not_found", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 15 + }, + "output": { + "rag_count": 0, + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/missing_runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 14 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "output": { + "passed": false, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved.", + "evidence_count": 0 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "path_scope_empty", + "answer_policy_branch": "open_file_not_found" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": false, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": false, + "answer_mode": "insufficient", + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "answer_policy_branch": "open_file_not_found", + "decision_reason": "path_scope_empty", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 0, + "empty": true, + "fallback_used": false + } + ], + "empty_layers": [ + "C0_SOURCE_CHUNKS" + ], + "evidence_gate_decision": { + "sufficient": false, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "evidence_count": 0 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "timings_ms": { + "router": 1, + "retrieval": 15, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json similarity index 78% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json index 32fe9ba..d0e1590 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-public-api", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/plba/__init__.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 1, - "llm_answer": "В файле src/plba/__init__.py видны следующие импорты и объявления:\n\n- from plba.bootstrap import create_runtime\n- from plba.config import ConfigFileLoader, FileConfigProvider\n- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\n- from plba.contracts import ApplicationModule, ConfigProvider, HealthContributor, TraceContext, TraceContextRecord, TraceLogMessage, TraceTransport, Worker, WorkerHealth, WorkerStatus\n- from plba.core import ConfigurationManager, RuntimeManager, ServiceContainer\n- from plba.health import HealthRegistry\n- from plba.logging import LogManager\n- from plba.queue import InMemoryTaskQueue\n- from plba.tracing import MySqlTraceTransport, NoOpTraceTransport, TraceService\n- from plba.workflow import StepResult, WorkflowContext, WorkflowDefinition, Workflo", + "llm_answer": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `ApplicationModule`, `ConfigProvider`, `HealthContributor`, `TraceContext`, `TraceContextRecord`, `TraceLogMessage`, `TraceTransport`, `Worker`, `WorkerHealth`, `WorkerStatus`\n- Из `plba.core`: `ConfigurationManager`, `RuntimeManager`, `ServiceContainer`\n- Из `plba.health`: `HealthRegistry`\n- Из `plba.logging`: `LogManager`\n- Из `plba.queue`: `InMemoryTaskQueue`\n- Из `plba.tracing`: `MySqlTraceTransport`, `NoOpTraceTransport`, `TraceService`\n- Из `plba.workflow`: `StepResult`, `WorkflowContext`, `WorkflowDefinition`, `WorkflowEngine` (упомянут частично)", "answer_mode": "answered", "path_scope": [ "src/plba/__init__.py" @@ -250,6 +250,7 @@ } ], "relations": [], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -322,7 +323,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 24 + "C0_SOURCE_CHUNKS": 36 } } }, @@ -334,6 +335,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -373,12 +377,43 @@ "failure_reasons": [], "evidence_count": 1 }, + "evidence_gate_input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `" + } + }, "failure_reasons": [], "timings_ms": { - "router": 0, - "retrieval": 24, - "pre_evidence_gate": 0, - "llm": 1406 + "router": 1, + "retrieval": 36, + "pre_evidence_gate": 1, + "llm": 5422, + "post_evidence_gate": 1 } }, "rag_rows": [ @@ -423,7 +458,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 1 }, "output": { "intent": "CODE_QA", @@ -436,7 +471,7 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 24 + "retrieval": 36 }, "output": { "rag_count": 1, @@ -476,7 +511,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 24 + "C0_SOURCE_CHUNKS": 36 } } }, @@ -484,36 +519,64 @@ "step": "pre_evidence_gate", "status": "passed", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] }, "output": { "passed": true, "failure_reasons": [], - "degraded_message": "" + "degraded_message": "", + "evidence_count": 1 } }, { "step": "llm", "status": "completed", "timings_ms": { - "llm": 1406 + "llm": 5422 }, "output": { "prompt_name": "code_qa_open_file_answer", - "answer_preview": "В файле src/plba/__init__.py видны следующие импорты и объявления:\n\n- from plba.bootstrap import create_runtime\n- from plba.config import ConfigFileLoader, FileConfigProvider\n- from plba.control import ControlActionSet, ControlChannel, ControlPlaneService, HttpControlChannel\n- from plba.contracts im" + "answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" } }, { "step": "post_evidence_gate", "status": "passed", "timings_ms": { - "post_evidence_gate": 0, + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, "repair": 0 }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `", + "repair_candidate": true + }, "output": { "passed": true, + "action": "return", "reasons": [], - "repair_used": false + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `" } } ] diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md new file mode 100644 index 0000000..afa6048 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-public-api.md @@ -0,0 +1,250 @@ +# plba-v2-open-file-public-api + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/plba/__init__.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 1, + "llm_answer": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `ApplicationModule`, `ConfigProvider`, `HealthContributor`, `TraceContext`, `TraceContextRecord`, `TraceLogMessage`, `TraceTransport`, `Worker`, `WorkerHealth`, `WorkerStatus`\n- Из `plba.core`: `ConfigurationManager`, `RuntimeManager`, `ServiceContainer`\n- Из `plba.health`: `HealthRegistry`\n- Из `plba.logging`: `LogManager`\n- Из `plba.queue`: `InMemoryTaskQueue`\n- Из `plba.tracing`: `MySqlTraceTransport`, `NoOpTraceTransport`, `TraceService`\n- Из `plba.workflow`: `StepResult`, `WorkflowContext`, `WorkflowDefinition`, `WorkflowEngine` (упомянут частично)", + "answer_mode": "answered", + "path_scope": [ + "src/plba/__init__.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 36 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/plba/__init__.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/plba/__init__.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 36 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 5422 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/plba/__init__.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/plba/__init__.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/plba/__init__.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 1 + }, + "evidence_gate_input": { + "resolved_target": "src/plba/__init__.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/plba/__init__.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/plba/__init__.py", + "draft_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Файл `src/plba/__init__.py` импортирует следующие основные компоненты:\n\n- Из `plba.bootstrap`: `create_runtime`\n- Из `plba.config`: `ConfigFileLoader`, `FileConfigProvider`\n- Из `plba.control`: `ControlActionSet`, `ControlChannel`, `ControlPlaneService`, `HttpControlChannel`\n- Из `plba.contracts`: `" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 36, + "pre_evidence_gate": 1, + "llm": 5422, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json similarity index 79% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json index 3df8028..4016ab4 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-runtime", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/app_runtime/core/runtime.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 1, - "llm_answer": "Виден класс `RuntimeManager` с инициализатором и статическими полями. Файл содержит 162 строки кода.", + "llm_answer": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n- `services: ServiceContainer | None`\n- `traces: TraceService | None`\n- `health: HealthRegistry | None`\n- `logs: LogManager | None`\n- `workers: WorkerSupervisor | None`\n- `control_plane: ControlPlaneService | None`\n\nЕсли аргумент не передан, используется значение по умолчанию – новый экземпляр соответствующего менеджера или сервиса.", "answer_mode": "answered", "path_scope": [ "src/app_runtime/core/runtime.py" @@ -250,6 +250,7 @@ } ], "relations": [], + "semantic_hints": [], "entrypoints": [], "test_candidates": [], "layer_outcomes": [ @@ -322,7 +323,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 136 + "C0_SOURCE_CHUNKS": 295 } } }, @@ -334,6 +335,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -373,8 +377,44 @@ "failure_reasons": [], "evidence_count": 1 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 295, + "pre_evidence_gate": 1, + "llm": 4019, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -412,6 +452,133 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 295 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 295 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4019 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md new file mode 100644 index 0000000..7666de1 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-open-file-runtime.md @@ -0,0 +1,250 @@ +# plba-v2-open-file-runtime + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/app_runtime/core/runtime.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 1, + "llm_answer": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n- `services: ServiceContainer | None`\n- `traces: TraceService | None`\n- `health: HealthRegistry | None`\n- `logs: LogManager | None`\n- `workers: WorkerSupervisor | None`\n- `control_plane: ControlPlaneService | None`\n\nЕсли аргумент не передан, используется значение по умолчанию – новый экземпляр соответствующего менеджера или сервиса.", + "answer_mode": "answered", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 295 + }, + "output": { + "rag_count": 1, + "answer_path_rag_count": 1, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 295 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 1 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4019 + }, + "output": { + "prompt_name": "code_qa_open_file_answer", + "answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/core/runtime.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 1, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 1 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "file", + "evidence_count": 1, + "code_chunk_count": 1, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/core/runtime.py", + "draft_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "В файле `src/app_runtime/core/runtime.py` определён класс `RuntimeManager`.\nУ него есть несколько атрибутов класса:\n- `ACTION_TIMEOUT_SECONDS = 10.0`\n- `ACTION_POLL_INTERVAL_SECONDS = 0.05`\n\nКонструктор принимает следующие параметры (все опциональны):\n- `configuration: ConfigurationManager | None`\n-" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 295, + "pre_evidence_gate": 1, + "llm": 4019, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json index e9e2341..3decbe7 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-trace-flow-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Покажи как проходит запрос /health в HttpControlAppFactory", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 37, - "llm_answer": "Поток выполнения запроса `/health` через `HttpControlAppFactory` выглядит следующим образом:\n\n1. Запрос приходит на сервер и обрабатывается фабрикой приложений `HttpControlAppFactory`.\n2. Внутри фабрики создается экземпляр приложения FastAPI с middleware для логирования времени обработки запросов.\n3. Для маршрута `/health` определяется обработчик, который вызывает предоставленный провайдер здоровья (`health_provider`), ожидающий асинхронный результат типа `HealthPayload`.\n4. В результате выполнения провайдера формируется JSON-ответ с кодом статуса 200 при успешном состоянии (\"ok\"), иначе возвращается статус 503.\n\nТаким образом, ключевой точкой является вызов провайдера здоровья внутри фабрики приложений, от которого зависит итоговый результат ответа.", + "llm_answer": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`health_provider`), переданного в фабрику приложений.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n3. Провайдер здоровья реализуется методом `_health_response` в классе `HttpControlChannel`. Он проверяет наличие действий (`_actions`) и возвращает статус здоровья.\n - Путь: `src/app_runtime/control/http_channel.py`\n - Строки: 44–50\n\nТаким образом, запрос `/health` проходит через эти компоненты для получения ответа о состоянии системы.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -135,13 +135,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "HttpControlAppFactory", "alternatives": [ - "health", - "HttpControlAppFactory" + "HttpControlAppFactory", + "HttpControlAppFactory", + "ControlActionSet", + "ControlPlaneService", + "HealthContributor.health" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1414,6 +1417,11 @@ "relations": [ { "path": "src/app_runtime/health/registry.py", + "start_line": 10, + "end_line": 13, + "edge_type": "dataflow_slice", + "source": "HealthRegistry.__init__", + "target": "HealthRegistry.register", "metadata": { "edge_id": "2381dfb339d541367c3251d2a610cac9d8b3f6bd6a352e119d00a93c5ccc2b7d", "edge_type": "dataflow_slice", @@ -1454,6 +1462,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1494,6 +1507,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1534,6 +1552,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1574,6 +1597,11 @@ }, { "path": "src/app_runtime/health/registry.py", + "start_line": 10, + "end_line": 16, + "edge_type": "dataflow_slice", + "source": "HealthRegistry.__init__", + "target": "HealthRegistry.contributor_healths", "metadata": { "edge_id": "d3a88a7abf16359e903e809ffc24473658fdd8198f60641fe1584fc4ac663c31", "edge_type": "dataflow_slice", @@ -1614,6 +1642,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1654,6 +1687,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1694,6 +1732,11 @@ }, { "path": "src/app_runtime/control/http_app.py", + "start_line": 25, + "end_line": 25, + "edge_type": "calls", + "source": "HttpControlAppFactory.create", + "target": "time.monotonic", "metadata": { "edge_id": "3fdd0a88d10225ee74f3b84ab57e13f09f5ccc72f00e31af9ae4655411c289c0", "edge_type": "calls", @@ -1718,6 +1761,11 @@ }, { "path": "src/app_runtime/control/http_app.py", + "start_line": 37, + "end_line": 37, + "edge_type": "calls", + "source": "HttpControlAppFactory.create", + "target": "app.post", "metadata": { "edge_id": "0e545d4b5187db7bec5ceac03071d2ad68177550c42af748fee364639e533c90", "edge_type": "calls", @@ -1742,6 +1790,11 @@ }, { "path": "src/app_runtime/control/http_app.py", + "start_line": 27, + "end_line": 27, + "edge_type": "calls", + "source": "HttpControlAppFactory.create", + "target": "str", "metadata": { "edge_id": "2a87c51461e31cd556508cc37fdff37b4d24c26f7f1604db30af5e8f1bda96cb", "edge_type": "calls", @@ -1765,37 +1818,83 @@ "content": "HttpControlAppFactory.create calls str" } ], + "semantic_hints": [ + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/health/registry.py", + "title": "HealthRegistry", + "symbol": "HealthRegistry", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HealthRegistry\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (2)" + }, + { + "path": "src/app_runtime/core/types.py", + "title": "HealthPayload", + "symbol": "HealthPayload", + "role": "model", + "confidence": 0.99, + "content": "HealthPayload\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/contracts/health.py", + "title": "HealthContributor", + "symbol": "HealthContributor", + "role": "model", + "confidence": 0.99, + "content": "HealthContributor\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + } + ], "entrypoints": [ - { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } - }, { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1823,6 +1922,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1846,6 +1952,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3267,11 +3407,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 36, - "C0_SOURCE_CHUNKS": 16, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 53, - "C3_ENTRYPOINTS": 12 + "C1_SYMBOL_CATALOG": 58, + "C0_SOURCE_CHUNKS": 21, + "C4_SEMANTIC_ROLES": 19, + "C2_DEPENDENCY_GRAPH": 54, + "C3_ENTRYPOINTS": 11 } } }, @@ -3287,6 +3427,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3301,7 +3444,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -3354,8 +3497,42 @@ "failure_reasons": [], "evidence_count": 37 }, + "evidence_gate_input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 165, + "pre_evidence_gate": 1, + "llm": 4961, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -4702,6 +4879,154 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 165 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlAppFactory", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 58, + "C0_SOURCE_CHUNKS": 21, + "C4_SEMANTIC_ROLES": 19, + "C2_DEPENDENCY_GRAPH": 54, + "C3_ENTRYPOINTS": 11 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4961 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md new file mode 100644 index 0000000..532c500 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-health-endpoint.md @@ -0,0 +1,306 @@ +# plba-v2-trace-flow-health-endpoint + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Покажи как проходит запрос /health в HttpControlAppFactory + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 37, + "llm_answer": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`health_provider`), переданного в фабрику приложений.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n3. Провайдер здоровья реализуется методом `_health_response` в классе `HttpControlChannel`. Он проверяет наличие действий (`_actions`) и возвращает статус здоровья.\n - Путь: `src/app_runtime/control/http_channel.py`\n - Строки: 44–50\n\nТаким образом, запрос `/health` проходит через эти компоненты для получения ответа о состоянии системы.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "health", + "HttpControlAppFactory" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 165 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "HttpControlAppFactory", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 58, + "C0_SOURCE_CHUNKS": 21, + "C4_SEMANTIC_ROLES": 19, + "C2_DEPENDENCY_GRAPH": 54, + "C3_ENTRYPOINTS": 11 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 4961 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "HttpControlAppFactory", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Покажи как проходит запрос /health в HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 10, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 37 + }, + "evidence_gate_input": { + "resolved_target": "HttpControlAppFactory", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "HttpControlAppFactory", + "draft_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Запрос `/health` обрабатывается следующим образом:\n\n1. В `HttpControlAppFactory` создаётся маршрут `@app.get(\"/health\")`, который вызывает функцию `health`.\n - Путь: `src/app_runtime/control/http_app.py`\n - Строки: 31–34\n\n2. Функция `health` асинхронно ожидает данные от провайдера здоровья (`hea" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 165, + "pre_evidence_gate": 1, + "llm": 4961, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json similarity index 93% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json rename to tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json index d03e20f..6ada923 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-trace-flow-runtime-start", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Покажи поток выполнения при запуске RuntimeManager", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 37, - "llm_answer": "При запуске `RuntimeManager` выполняются следующие основные шаги:\n\n1. Инициализация через `RuntimeManager.__init__` в файле `src/app_runtime/core/runtime.py`.\n2. Вызов метода `start` внутри `RuntimeManager`, который далее вызывает асинхронную функцию `_start_async`.\n3. В `ControlPlaneService.start` создается экземпляр канала управления с помощью метода `register_channel`.\n4. Канал управления инициализируется через метод `start` экземпляра `ControlChannel`, где создается веб-приложение с использованием фабрики `HttpControlAppFactory`.\n5. Веб-приложение запускается с помощью `UvicornThreadRunner.start`, который выполняет запуск сервера через uvicorn.\n\nТаким образом, поток начинается с инициализации менеджера времени выполнения и завершается запуском веб-канала управления.", + "llm_answer": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core_services`.\n5. Старт менеджера методом `start`.\n\nЭти шаги соответствуют обнаруженному коду в файле `src/app_runtime/core/runtime.py`. \n\nДальнейший поток выполнения внутри методов (`_register_core_services`, `start`) восстановить полностью не представляется возможным, поскольку вызываемый код отсутствует в текущем контексте.", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -120,12 +120,16 @@ } }, "symbol_resolution": { - "status": "pending", - "resolved_symbol": null, + "status": "resolved", + "resolved_symbol": "RuntimeManager", "alternatives": [ + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", + "RuntimeManager", "RuntimeManager" ], - "confidence": 0.0 + "confidence": 0.99 }, "evidence_policy": { "require_def": true, @@ -1431,6 +1435,11 @@ "relations": [ { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 52, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.add_config_file", "metadata": { "edge_id": "a23b8a11ebdb12708b60c96ea12a69f7f042082f1adfddd572444e246d81d167", "edge_type": "dataflow_slice", @@ -1471,6 +1480,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 33, + "end_line": 39, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.__init__", "metadata": { "edge_id": "d43af85989222ee6d788ce418cdcb217c7ff044cfb915e3bdbd184417dc7bd61", "edge_type": "dataflow_slice", @@ -1511,6 +1525,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 25, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.stop", "metadata": { "edge_id": "d5433e2950fb6f913453de2694d697f2c5c5b0e759501aa31c37125d4d29c118", "edge_type": "dataflow_slice", @@ -1551,6 +1570,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 51, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._stop_async", "metadata": { "edge_id": "991ae894d11340626f4d9361e176c5009c2f33d95ce1a8864740bc85306accc3", "edge_type": "dataflow_slice", @@ -1591,6 +1615,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 59, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager.start", "metadata": { "edge_id": "98312ace7fc62b1c7194c5aa1732b6ef736eae1668a3a120dd1ecd5ab1d64f7a", "edge_type": "dataflow_slice", @@ -1631,6 +1660,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 32, + "end_line": 127, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager._register_core_services", "metadata": { "edge_id": "3e5811f3b511fa0cabe363f5d01f2ac5fa039bc8b93f7ee108323e1f5f45a293", "edge_type": "dataflow_slice", @@ -1671,6 +1705,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 17, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.register_channel", "metadata": { "edge_id": "e21fe35e6cd37bb929561a316c9b5156bd379de768b11d96c989a75a4a9330f2", "edge_type": "dataflow_slice", @@ -1711,6 +1750,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 20, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService.start", "metadata": { "edge_id": "dc85f1ea8fe46c5223a32b4623a249512af7ea30f3af0d890c2fbe842c74d3c2", "edge_type": "dataflow_slice", @@ -1751,6 +1795,11 @@ }, { "path": "src/app_runtime/control/service.py", + "start_line": 14, + "end_line": 47, + "edge_type": "dataflow_slice", + "source": "ControlPlaneService.__init__", + "target": "ControlPlaneService._start_async", "metadata": { "edge_id": "e8e2ddef7499bed745cce7a83d5130d145e9787ca9ddc73f5898372a8da2be06", "edge_type": "dataflow_slice", @@ -1791,6 +1840,11 @@ }, { "path": "src/app_runtime/core/runtime.py", + "start_line": 33, + "end_line": 127, + "edge_type": "dataflow_slice", + "source": "RuntimeManager.__init__", + "target": "RuntimeManager._register_core_services", "metadata": { "edge_id": "aac6f9dda73963b977083a892bee39a48eca4fbd7404787e022ecf4ebedec65d", "edge_type": "dataflow_slice", @@ -1830,37 +1884,83 @@ "content": "RuntimeManager.__init__\n -> RuntimeManager.services\n -> RuntimeManager._register_core_services" } ], - "entrypoints": [ + "semantic_hints": [ { - "path": "src/app_runtime/control/http_app.py", - "title": "app.post", - "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", - "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, - "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", - "repo_id": "plba", - "section": null, - "doc_id": null, - "doc_version": null, - "owner": null, - "system_component": null, - "last_modified": null, - "staleness_score": null - } + "path": "src/app_runtime/core/runtime.py", + "title": "RuntimeManager", + "symbol": "RuntimeManager", + "role": "pipeline_stage", + "confidence": 0.67, + "content": "RuntimeManager\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests manager\n- orchestrates role-like calls (4)\n- reads and writes state attributes\n- participates in dataflow slices (50)" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlChannel", + "symbol": "ControlChannel", + "role": "model", + "confidence": 0.99, + "content": "ControlChannel\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/base.py", + "title": "ControlActionSet", + "symbol": "ControlActionSet", + "role": "model", + "confidence": 0.99, + "content": "ControlActionSet\nrole: model\n\nResponsibilities:\n- default model role" + }, + { + "path": "src/app_runtime/control/service.py", + "title": "ControlPlaneService", + "symbol": "ControlPlaneService", + "role": "pipeline_stage", + "confidence": 0.57, + "content": "ControlPlaneService\nrole: pipeline_stage\n\nResponsibilities:\n- name suffix suggests service\n- reads and writes state attributes\n- participates in dataflow slices (5)" + }, + { + "path": "src/app_runtime/control/http_runner.py", + "title": "UvicornThreadRunner", + "symbol": "UvicornThreadRunner", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "UvicornThreadRunner\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (24)" + }, + { + "path": "src/app_runtime/control/http_channel.py", + "title": "HttpControlChannel", + "symbol": "HttpControlChannel", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "HttpControlChannel\nrole: pipeline_stage\n\nResponsibilities:\n- reads and writes state attributes\n- participates in dataflow slices (10)" }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "HttpControlAppFactory", + "symbol": "HttpControlAppFactory", + "role": "factory", + "confidence": 0.99, + "content": "HttpControlAppFactory\nrole: factory\n\nResponsibilities:\n- name suffix suggests factory" + }, + { + "path": "src/app_runtime/workflow/persistence/workflow_persistence.py", + "title": "WorkflowPersistence", + "symbol": "WorkflowPersistence", + "role": "pipeline_stage", + "confidence": 0.99, + "content": "WorkflowPersistence\nrole: pipeline_stage\n\nResponsibilities:\n- orchestrates role-like calls (2)\n- reads and writes state attributes\n- participates in dataflow slices (16)" + } + ], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -1888,6 +1988,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -1911,6 +2018,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -3380,11 +3521,11 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 37, - "C0_SOURCE_CHUNKS": 16, - "C4_SEMANTIC_ROLES": 13, - "C2_DEPENDENCY_GRAPH": 54, - "C3_ENTRYPOINTS": 9 + "C1_SYMBOL_CATALOG": 43, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 16, + "C2_DEPENDENCY_GRAPH": 61, + "C3_ENTRYPOINTS": 12 } } }, @@ -3400,6 +3541,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -3414,7 +3558,7 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "resolved" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -3467,8 +3611,42 @@ "failure_reasons": [], "evidence_count": 37 }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core" + } + }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 154, + "pre_evidence_gate": 1, + "llm": 3180, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -4863,6 +5041,154 @@ "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 154 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 43, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 16, + "C2_DEPENDENCY_GRAPH": 61, + "C3_ENTRYPOINTS": 12 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3180 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md new file mode 100644 index 0000000..3e43f45 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/full_chain_plba_code_subintents_v2_plba-v2-trace-flow-runtime-start.md @@ -0,0 +1,305 @@ +# plba-v2-trace-flow-runtime-start + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Покажи поток выполнения при запуске RuntimeManager + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 37, + "llm_answer": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core_services`.\n5. Старт менеджера методом `start`.\n\nЭти шаги соответствуют обнаруженному коду в файле `src/app_runtime/core/runtime.py`. \n\nДальнейший поток выполнения внутри методов (`_register_core_services`, `start`) восстановить полностью не представляется возможным, поскольку вызываемый код отсутствует в текущем контексте.", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "RuntimeManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "TRACE_FLOW", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 154 + }, + "output": { + "rag_count": 37, + "answer_path_rag_count": 37, + "resolved_symbol_status": "resolved", + "resolved_symbol": "RuntimeManager", + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 10, + "C3_ENTRYPOINTS": 10 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 43, + "C0_SOURCE_CHUNKS": 20, + "C4_SEMANTIC_ROLES": 16, + "C2_DEPENDENCY_GRAPH": 61, + "C3_ENTRYPOINTS": 12 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 37 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3180 + }, + "output": { + "prompt_name": "code_qa_trace_flow_answer", + "answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "RuntimeManager", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "resolved" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Покажи поток выполнения при запуске RuntimeManager", + "sub_intent": "TRACE_FLOW", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 8, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 10, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 37 + }, + "evidence_gate_input": { + "resolved_target": "RuntimeManager", + "sub_intent": "TRACE_FLOW", + "target_type": "symbol", + "evidence_count": 37, + "code_chunk_count": 37, + "entrypoint_count": 3, + "relation_count": 10, + "test_evidence_count": 0, + "symbol_resolution_status": "resolved", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "RuntimeManager", + "draft_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "При запуске `RuntimeManager` выполняются следующие шаги:\n\n1. Инициализация конфигурации через поле `configuration`.\n2. Добавление конфигурационных файлов методом `add_config_file`.\n3. Инициализация сервисов методом `__init__` внутри конструктора.\n4. Регистрация основных служб методом `_register_core" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 154, + "pre_evidence_gate": 1, + "llm": 3180, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/summary.md b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/summary.md new file mode 100644 index 0000000..bba7737 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_192715/summary.md @@ -0,0 +1,80 @@ +# pipeline_setup_v3 summary + +Passed: 18/18 + +| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | +|------|------|------|-------|-------------------|------------|------| +| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-runtime | full_chain | Открой файл src/app_runtime/core/runtime.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-public-api | full_chain | Открой файл src/plba/__init__.py | OPEN_FILE | C0_SOURCE_CHUNKS:1 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-runtime-manager | full_chain | Объясни как работает класс RuntimeManager | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-trace-service | full_chain | Объясни как работает класс TraceService | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-create-runtime | full_chain | Что делает функция create_runtime? | EXPLAIN | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-local-http-channel | full_chain | Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? | EXPLAIN_LOCAL | C0_SOURCE_CHUNKS:1, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:4 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-runtime-manager | full_chain | Где тесты для RuntimeManager? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-trace-service | full_chain | Где тесты для TraceService? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-create-runtime | full_chain | Где тесты для create_runtime? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-tests-workflow-runtime-factory-negative | full_chain | Где тесты для WorkflowRuntimeFactory? | FIND_TESTS | C0_SOURCE_CHUNKS:10, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:6 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-control-plane | full_chain | Найди точки входа HTTP control plane | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:6, C3_ENTRYPOINTS:3 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:7, C3_ENTRYPOINTS:3 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-runtime-start | full_chain | Покажи поток выполнения при запуске RuntimeManager | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-trace-flow-health-endpoint | full_chain | Покажи как проходит запрос /health в HttpControlAppFactory | TRACE_FLOW | C0_SOURCE_CHUNKS:8, C1_SYMBOL_CATALOG:8, C2_DEPENDENCY_GRAPH:10, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:8 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-runtime-manager | full_chain | Какие компоненты участвуют в RuntimeManager? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-architecture-control-plane | full_chain | Какие компоненты участвуют в ControlPlaneService? | ARCHITECTURE | C0_SOURCE_CHUNKS:4, C1_SYMBOL_CATALOG:6, C2_DEPENDENCY_GRAPH:8, C3_ENTRYPOINTS:3, C4_SEMANTIC_ROLES:12 | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | — | ✓ | +| full_chain_plba_code_subintents_v2.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✓ | + +## LLM Answers +- **plba-v2-open-file-runtime** + Query: Открой файл src/app_runtime/core/runtime.py + > В файле \`src/app\_runtime/core/runtime.py\` определён класс \`RuntimeManager\`. У него есть несколько атрибутов класса: \- \`ACTION\_TIMEOUT\_SECONDS = 10.0\` \- \`ACTION\_POLL\_INTERVAL\_SECONDS = 0.05\` Конструктор принимает следующие параметры \(все опциональны\): \- \`configuration: ConfigurationManager \| None\` \- \`services: ServiceContainer \| None\` \- \`traces: TraceService \| None\` \- \`health: HealthRegistry \| None\` \- \`logs: LogManager \| None\` \- \`workers: WorkerSupervisor \| None\` \- \`control\_plane: ControlPlaneService \| None\` Если аргумент не передан, используется значение по умолчанию – новый экземпляр соответствующего менеджера или сервиса. +- **plba-v2-open-file-public-api** + Query: Открой файл src/plba/__init__.py + > Файл \`src/plba/\_\_init\_\_.py\` импортирует следующие основные компоненты: \- Из \`plba.bootstrap\`: \`create\_runtime\` \- Из \`plba.config\`: \`ConfigFileLoader\`, \`FileConfigProvider\` \- Из \`plba.control\`: \`ControlActionSet\`, \`ControlChannel\`, \`ControlPlaneService\`, \`HttpControlChannel\` \- Из \`plba.contracts\`: \`ApplicationModule\`, \`ConfigProvider\`, \`HealthContributor\`, \`TraceContext\`, \`TraceContextRecord\`, \`TraceLogMessage\`, \`TraceTransport\`, \`Worker\`, \`WorkerHealth\`, \`WorkerStatus\` \- Из \`plba.core\`: \`ConfigurationManager\`, \`RuntimeManager\`, \`ServiceContainer\` \- Из \`plba.health\`: \`HealthRegistry\` \- Из \`plba.logging\`: \`LogManager\` \- Из \`plba.queue\`: \`InMemoryTaskQueue\` \- Из \`plba.tracing\`: \`MySqlTraceTransport\`, \`NoOpTraceTransport\`, \`TraceService\` \- Из \`plba.workflow\`: \`StepResult\`, \`WorkflowContext\`, \`WorkflowDefinition\`, \`WorkflowEngine\` \(упомянут частично\) +- **plba-v2-explain-runtime-manager** + Query: Объясни как работает класс RuntimeManager + > Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager. +- **plba-v2-explain-trace-service** + Query: Объясни как работает класс TraceService + > Недостаточно подтверждённых данных для уверенного ответа по TraceService. +- **plba-v2-explain-create-runtime** + Query: Что делает функция create_runtime? + > Функция \`create\_runtime\` определена в файле \`src/plba/bootstrap.py\`. Она создаёт и конфигурирует экземпляр \`RuntimeManager\`, регистрируя модуль приложения и опционально добавляя файл конфигурации и HTTP\-канал управления. Основные действия функции: \- Создаёт экземпляр \`RuntimeManager\`. \- Если передан путь к конфигурационному файлу, вызывает \`runtime.add\_config\_file\(config\_path\)\` для добавления конфигурации. \- Если включён HTTP\-контроль, регистрирует HTTP\-канал управления через \`runtime.control\_plane.register\_channel\(HttpControlChannel\(host=control\_host, port=control\_port, timeout=control\_timeout\)\)\`. \- Регистрирует модуль приложения методом \`runtime.register\_module\(module\)\`. Возвращает сконфигурированный объект типа \`RuntimeManager\`. +- **plba-v2-explain-local-http-channel** + Query: Почему в файле src/app_runtime/control/http_channel.py класс HttpControlChannel устроен так? + > Класс HttpControlChannel наследует ControlChannel и управляет HTTP\-каналом контроля. Инициализация задает хост, порт, таймаут, создаёт экземпляр UvicornThreadRunner для запуска сервера и HttpControlAppFactory для создания FastAPI\-приложения. Метод start запускает сервер с приложением, используя фабрики и передавая коллбэки здоровья и действий. Методы \_health\_response и \_action\_response \(не полностью показаны\) вероятно отвечают за обработчики API\-эндпоинтов здоровья и выполнения действий. Остальные детали, такие как полный контекст методов или их реализации, отсутствуют в данном фрагменте. +- **plba-v2-find-tests-runtime-manager** + Query: Где тесты для RuntimeManager? + > Прямые тесты для \`RuntimeManager\` находятся в файле \`tests/test\_runtime.py\`. Косвенные тесты: \- В файле \`tests/test\_business\_control\_actions.py\` есть тесты, использующие компоненты контроля, которые взаимодействуют с \`RuntimeManager\`. +- **plba-v2-find-tests-trace-service** + Query: Где тесты для TraceService? + > Прямые тесты для TraceService находятся в файле \`tests/test\_runtime.py\`: \- \`test\_trace\_service\_allows\_messages\_without\_status\`: проверяет возможность отправки сообщений без статуса. \- \`test\_trace\_service\_writes\_contexts\_and\_messages\`: проверяет запись контекстов и сообщений. \- \`test\_trace\_service\_supports\_debug\_warning\_and\_error\_levels\`: проверяет поддержку уровней debug, warning и error. +- **plba-v2-find-tests-create-runtime** + Query: Где тесты для create_runtime? + > Прямые тесты для \`create\_runtime\` не найдены. Ближайший косвенный тест: \- \`tests/test\_runtime.py::test\_public\_plba\_package\_exports\_runtime\_builder\_and\_worker\_contract\` \- Проверяет экспорт пакета plba и доступность создания runtime, включая worker контракты. +- **plba-v2-find-tests-workflow-runtime-factory-negative** + Query: Где тесты для WorkflowRuntimeFactory? + > Insufficient evidence for a confident answer. No test candidates found. +- **plba-v2-find-entrypoints-control-plane** + Query: Найди точки входа HTTP control plane + > Подтверждённые HTTP routes: 1. GET /health — обработчик \`health\`, объявлен в \`src/app\_runtime/control/http\_app.py\`:31\-34. 2. GET /actions/\{action\} — обработчик \`action\`, объявлен в \`src/app\_runtime/control/http\_app.py\`:38\-42. 3. POST /actions/\{action\} — обработчик \`action\`, объявлен в \`src/app\_runtime/control/http\_app.py\`:38\-42. Кандидаты на входные точки отсутствуют. +- **plba-v2-find-entrypoints-health-endpoint** + Query: Где health endpoint? + > Подтверждённая точка входа для health endpoint: GET /health, declared in src/app\_runtime/control/http\_app.py, lines 31\-34, handler function named 'health'. +- **plba-v2-trace-flow-runtime-start** + Query: Покажи поток выполнения при запуске RuntimeManager + > При запуске \`RuntimeManager\` выполняются следующие шаги: 1. Инициализация конфигурации через поле \`configuration\`. 2. Добавление конфигурационных файлов методом \`add\_config\_file\`. 3. Инициализация сервисов методом \`\_\_init\_\_\` внутри конструктора. 4. Регистрация основных служб методом \`\_register\_core\_services\`. 5. Старт менеджера методом \`start\`. Эти шаги соответствуют обнаруженному коду в файле \`src/app\_runtime/core/runtime.py\`. Дальнейший поток выполнения внутри методов \(\`\_register\_core\_services\`, \`start\`\) восстановить полностью не представляется возможным, поскольку вызываемый код отсутствует в текущем контексте. +- **plba-v2-trace-flow-health-endpoint** + Query: Покажи как проходит запрос /health в HttpControlAppFactory + > Запрос \`/health\` обрабатывается следующим образом: 1. В \`HttpControlAppFactory\` создаётся маршрут \`@app.get\("/health"\)\`, который вызывает функцию \`health\`. \- Путь: \`src/app\_runtime/control/http\_app.py\` \- Строки: 31–34 2. Функция \`health\` асинхронно ожидает данные от провайдера здоровья \(\`health\_provider\`\), переданного в фабрику приложений. \- Путь: \`src/app\_runtime/control/http\_app.py\` \- Строки: 31–34 3. Провайдер здоровья реализуется методом \`\_health\_response\` в классе \`HttpControlChannel\`. Он проверяет наличие действий \(\`\_actions\`\) и возвращает статус здоровья. \- Путь: \`src/app\_runtime/control/http\_channel.py\` \- Строки: 44–50 Таким образом, запрос \`/health\` проходит через эти компоненты для получения ответа о состоянии системы. +- **plba-v2-architecture-runtime-manager** + Query: Какие компоненты участвуют в RuntimeManager? + > Недостаточно подтверждённых данных для уверенного ответа по RuntimeManager. +- **plba-v2-architecture-control-plane** + Query: Какие компоненты участвуют в ControlPlaneService? + > \*\*ControlPlaneService\*\* является главным компонентом, управляющим жизненным циклом контролируемых каналов. Компоненты: \- \*\*ControlPlaneService\*\* \- \*\*ControlPlaneService.\_\_init\_\_\*\*: инициализирует сервис, регистрирует каналы и запускает асинхронные операции. \- \*\*ControlPlaneService.start\*\*: начинает работу сервиса, вызывая asyncio.run и читая атрибут \_channels. \- \*\*ControlPlaneService.register\_channel\*\*: регистрирует канал, читая атрибут \_channels. \- \*\*ControlPlaneService.stop\*\*, \*\*ControlPlaneService.\_stop\_async\*\*: останавливают сервисы. \- \*\*ControlPlaneService.\_start\_async\*\*: отвечает за асинхронный старт. \- \*\*ControlChannel\*\*: абстрактный базовый класс всех каналов контроля с методами start и stop. Связи между компонентами: \- Инициализация \(ControlPlaneService.\_\_init\_\_\) выполняет dataflow\_slice для методов регистрации и старта. \- Метод старта \(ControlPlaneService.s… +- **plba-v2-explain-nonexistent-symbol** + Query: Объясни класс RuntimeFactoryManager + > Сущность RuntimeFactoryManager не найдена в доступном коде. +- **plba-v2-open-file-nonexistent** + Query: Открой файл src/app_runtime/core/missing_runtime.py + > Файл src/app\_runtime/core/missing\_runtime.py не найден. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json b/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.json similarity index 65% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json rename to tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.json index bd7f711..8e5606b 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_163609/full_chain_plba_code_subintents_v2_plba-v2-open-file-nonexistent.json +++ b/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-open-file-nonexistent", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/tmp/full_chain_plba_last_case.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Открой файл src/app_runtime/core/missing_runtime.py", @@ -10,7 +10,7 @@ "graph_id": "CodeQAGraph", "conversation_mode": "START", "rag_count": 0, - "llm_answer": "Файл `src/app_runtime/core/missing_runtime.py` не найден.", + "llm_answer": "Файл src/app_runtime/core/missing_runtime.py не найден.", "answer_mode": "not_found", "path_scope": [ "src/app_runtime/core/missing_runtime.py" @@ -20,11 +20,8 @@ "C0_SOURCE_CHUNKS" ] }, - "passed": false, - "mismatches": [ - "answer_mode: expected degraded, got not_found", - "llm: expected answer to contain 'Файл src/app_runtime/core/missing_runtime.py не найден.'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Открой файл src/app_runtime/core/missing_runtime.py", "router_result": { @@ -269,7 +266,7 @@ "reason": null }, "retrieval_by_layer_ms": { - "C0_SOURCE_CHUNKS": 13 + "C0_SOURCE_CHUNKS": 147 } } }, @@ -281,6 +278,9 @@ ], "retrieval_sufficient": false, "answer_mode": "insufficient", + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "answer_policy_branch": "open_file_not_found", + "decision_reason": "path_scope_empty", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -325,17 +325,167 @@ ], "evidence_count": 0 }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + }, "failure_reasons": [ "path_scope_empty", "layer_c0_empty" ], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 148, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } }, "rag_rows": [], "validation": { "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 148 + }, + "output": { + "rag_count": 0, + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/missing_runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 147 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "output": { + "passed": false, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved.", + "evidence_count": 0 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "path_scope_empty", + "answer_policy_branch": "open_file_not_found" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.md b/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.md new file mode 100644 index 0000000..8ba35f3 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/full_chain_plba_last_case_plba-v2-open-file-nonexistent.md @@ -0,0 +1,245 @@ +# plba-v2-open-file-nonexistent + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/tmp/full_chain_plba_last_case.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Открой файл src/app_runtime/core/missing_runtime.py + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 0, + "llm_answer": "Файл src/app_runtime/core/missing_runtime.py не найден.", + "answer_mode": "not_found", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ], + "symbol_candidates": [], + "layers": [ + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "OPEN_FILE", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 148 + }, + "output": { + "rag_count": 0, + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_requested", + "resolved_symbol": null, + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C0_SOURCE_CHUNKS": 200 + }, + "filters_by_layer": { + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + } + }, + "requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Открой файл src/app_runtime/core/missing_runtime.py", + "ranking_profile": "code" + } + ], + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C0_SOURCE_CHUNKS": 147 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "output": { + "passed": false, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "degraded_message": "Insufficient evidence for a confident answer. No matching path or file found. No code chunks retrieved.", + "evidence_count": 0 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "path_scope_empty", + "answer_policy_branch": "open_file_not_found" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": false, + "layers_used": [ + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": false, + "answer_mode": "insufficient", + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "answer_policy_branch": "open_file_not_found", + "decision_reason": "path_scope_empty", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ], + "layers": [ + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_requested" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Открой файл src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ], + "requested_layers": [ + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 0, + "empty": true, + "fallback_used": false + } + ], + "empty_layers": [ + "C0_SOURCE_CHUNKS" + ], + "evidence_gate_decision": { + "sufficient": false, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "evidence_count": 0 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/core/missing_runtime.py", + "sub_intent": "OPEN_FILE", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_requested", + "path_scope": [ + "src/app_runtime/core/missing_runtime.py" + ] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": "src/app_runtime/core/missing_runtime.py" + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "path_scope_empty", + "layer_c0_empty" + ], + "timings_ms": { + "router": 1, + "retrieval": 148, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/summary.md b/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/summary.md new file mode 100644 index 0000000..255e59d --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_last_case_v3/20260312_165845/summary.md @@ -0,0 +1,12 @@ +# pipeline_setup_v3 summary + +Passed: 1/1 + +| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | +|------|------|------|-------|-------------------|------------|------| +| full_chain_plba_last_case.yaml | plba-v2-open-file-nonexistent | full_chain | Открой файл src/app_runtime/core/missing_runtime.py | OPEN_FILE | — | ✓ | + +## LLM Answers +- **plba-v2-open-file-nonexistent** + Query: Открой файл src/app_runtime/core/missing_runtime.py + > Файл src/app\_runtime/core/missing\_runtime.py не найден. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.json b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.json new file mode 100644 index 0000000..fd8447b --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.json @@ -0,0 +1,632 @@ +{ + "case_id": "plba-v2-explain-nonexistent-symbol", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml", + "runner": "agent_runtime", + "mode": "full_chain", + "query": "Объясни класс RuntimeFactoryManager", + "actual": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 0, + "llm_answer": "Сущность RuntimeFactoryManager не найдена в доступном коде.", + "answer_mode": "not_found", + "path_scope": [], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "passed": true, + "mismatches": [], + "details": { + "query": "Объясни класс RuntimeFactoryManager", + "router_result": { + "schema_version": "1.1", + "intent": "CODE_QA", + "retrieval_profile": "code", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "query_plan": { + "raw": "Объясни класс RuntimeFactoryManager", + "normalized": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "negations": [], + "expansions": [ + "RuntimeFactoryManager" + ], + "keyword_hints": [ + "RuntimeFactoryManager" + ], + "path_hints": [], + "doc_scope_hints": [], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "symbol_kind_hint": "class", + "anchors": [ + { + "type": "SYMBOL", + "value": "RuntimeFactoryManager", + "source": "user_text", + "subtype": null, + "span": { + "start": 14, + "end": 35 + }, + "confidence": 0.88 + }, + { + "type": "KEY_TERM", + "value": "класс", + "source": "user_text", + "subtype": null, + "span": { + "start": 8, + "end": 13 + }, + "confidence": 0.9 + } + ] + }, + "retrieval_spec": { + "domains": [ + "CODE" + ], + "layer_queries": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "top_k": 8 + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "top_k": 8 + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "top_k": 8 + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "top_k": 6 + }, + { + "layer_id": "C3_ENTRYPOINTS", + "top_k": 6 + } + ], + "filters": { + "test_policy": "EXCLUDE", + "path_scope": [], + "language": [ + "python" + ] + }, + "rerank_profile": "code" + }, + "retrieval_constraints": { + "include_globs": [ + "src/**" + ], + "exclude_globs": [ + "tests/**", + "**/test_*.py", + "**/*_test.py" + ], + "prefer_globs": [], + "test_file_globs": [], + "test_symbol_patterns": [], + "max_candidates": 20, + "fuzzy_symbol_search": { + "enabled": true, + "max_distance": 2, + "top_k": 5 + } + }, + "symbol_resolution": { + "status": "not_found", + "resolved_symbol": null, + "alternatives": [], + "confidence": 0.0 + }, + "evidence_policy": { + "require_def": true, + "require_flow": true, + "require_spec": false, + "allow_answer_without_evidence": false + } + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "keyword_hints": [ + "RuntimeFactoryManager" + ], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_spec": { + "domains": [ + "CODE" + ], + "layer_queries": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "top_k": 8 + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "top_k": 8 + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "top_k": 8 + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "top_k": 6 + }, + { + "layer_id": "C3_ENTRYPOINTS", + "top_k": 6 + } + ], + "filters": { + "test_policy": "EXCLUDE", + "path_scope": [], + "language": [ + "python" + ] + }, + "rerank_profile": "code" + }, + "retrieval_constraints": { + "include_globs": [ + "src/**" + ], + "exclude_globs": [ + "tests/**", + "**/test_*.py", + "**/*_test.py" + ], + "prefer_globs": [], + "test_file_globs": [], + "test_symbol_patterns": [], + "max_candidates": 20, + "fuzzy_symbol_search": { + "enabled": true, + "max_distance": 2, + "top_k": 5 + } + }, + "query_plan": { + "raw": "Объясни класс RuntimeFactoryManager", + "normalized": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "negations": [], + "expansions": [ + "RuntimeFactoryManager" + ], + "keyword_hints": [ + "RuntimeFactoryManager" + ], + "path_hints": [], + "doc_scope_hints": [], + "symbol_candidates": [ + "RuntimeFactoryManager" + ], + "symbol_kind_hint": "class", + "anchors": [ + { + "type": "SYMBOL", + "value": "RuntimeFactoryManager", + "source": "user_text", + "subtype": null, + "span": { + "start": 14, + "end": 35 + }, + "confidence": 0.88 + }, + { + "type": "KEY_TERM", + "value": "класс", + "source": "user_text", + "subtype": null, + "span": { + "start": 8, + "end": 13 + }, + "confidence": 0.9 + } + ] + } + }, + "retrieval_result": { + "target_symbol_candidates": [], + "resolved_symbol": null, + "symbol_resolution_status": "not_found", + "file_candidates": [], + "code_chunks": [], + "relations": [], + "entrypoints": [], + "test_candidates": [], + "layer_outcomes": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 0, + "empty": true, + "fallback_used": false + } + ], + "missing_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "raw_rows": [], + "retrieval_report": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 32, + "C0_SOURCE_CHUNKS": 22, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 58, + "C3_ENTRYPOINTS": 13 + } + } + }, + "diagnostics": { + "intent_correct": null, + "target_found": false, + "layers_used": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_sufficient": false, + "answer_mode": "insufficient", + "resolved_target": null, + "answer_policy_branch": "explain_not_found", + "decision_reason": "symbol_resolution_not_found", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "EXPLAIN", + "path_scope": [], + "layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Объясни класс RuntimeFactoryManager", + "sub_intent": "EXPLAIN", + "path_scope": [], + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C1_SYMBOL_CATALOG", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C4_SEMANTIC_ROLES", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C2_DEPENDENCY_GRAPH", + "hit_count": 0, + "empty": true, + "fallback_used": false + }, + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 0, + "empty": true, + "fallback_used": false + } + ], + "empty_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "evidence_gate_decision": { + "sufficient": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "evidence_count": 0 + }, + "evidence_gate_input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "insufficient_evidence" + ], + "timings_ms": { + "router": 2, + "retrieval": 145, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 + } + }, + "rag_rows": [], + "validation": { + "passed": true, + "action": "return", + "reasons": [] + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 2 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "EXPLAIN", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 145 + }, + "output": { + "rag_count": 33, + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], + "retrieval_mode_by_layer": { + "C1_SYMBOL_CATALOG": "vector", + "C0_SOURCE_CHUNKS": "vector", + "C4_SEMANTIC_ROLES": "vector", + "C2_DEPENDENCY_GRAPH": "vector", + "C3_ENTRYPOINTS": "vector" + }, + "top_k_by_layer": { + "C1_SYMBOL_CATALOG": 8, + "C0_SOURCE_CHUNKS": 8, + "C4_SEMANTIC_ROLES": 8, + "C2_DEPENDENCY_GRAPH": 6, + "C3_ENTRYPOINTS": 6 + }, + "filters_by_layer": { + "C1_SYMBOL_CATALOG": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [] + }, + "C4_SEMANTIC_ROLES": { + "path_scope": [] + }, + "C2_DEPENDENCY_GRAPH": { + "path_scope": [] + }, + "C3_ENTRYPOINTS": { + "path_scope": [] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C1_SYMBOL_CATALOG": 32, + "C0_SOURCE_CHUNKS": 22, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 58, + "C3_ENTRYPOINTS": 13 + } + } + }, + { + "step": "pre_evidence_gate", + "status": "blocked", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met).", + "evidence_count": 0 + } + }, + { + "step": "llm", + "status": "skipped", + "timings_ms": { + "llm": 1 + }, + "output": { + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "symbol_resolution_not_found", + "answer_policy_branch": "explain_not_found" + } + }, + { + "step": "post_evidence_gate", + "status": "skipped", + "timings_ms": { + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + } + ] + } +} \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.md similarity index 52% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md rename to tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.md index 29eda0e..8b724d9 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_164751/full_chain_plba_code_subintents_v2_plba-v2-explain-runtime-manager.md +++ b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-explain-nonexistent-symbol.md @@ -1,12 +1,12 @@ -# plba-v2-explain-runtime-manager +# plba-v2-explain-nonexistent-symbol -- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml - runner: agent_runtime - mode: full_chain - passed: True ## Query -Объясни как работает класс RuntimeManager +Объясни класс RuntimeFactoryManager ## Actual { @@ -14,12 +14,12 @@ "sub_intent": "EXPLAIN", "graph_id": "CodeQAGraph", "conversation_mode": "START", - "rag_count": 33, - "llm_answer": "Класс `RuntimeManager` находится в файле `src/app_runtime/core/runtime.py`. Конкретной реализации инициализации или подробного описания методов в предоставленном контексте не видно. Однако исходя из имеющихся признаков:\n\n1. Класс имеет ответственность за управление состоянием и конфигурацией runtime-системы, судя по названиям атрибутов и методов в окружении (`configuration`, `add_config_file`).\n2. Вероятно, он участвует в оркестрации различных компонентов системы через свои методы и атрибуты, хотя детальной информации об этих методах и атрибутах нет.\n\nТаким образом, класс `RuntimeManager` играет ключевую управляющую роль в системе, вероятно, интегрируя и координируя другие компоненты и модули.", - "answer_mode": "answered", + "rag_count": 0, + "llm_answer": "Сущность RuntimeFactoryManager не найдена в доступном коде.", + "answer_mode": "not_found", "path_scope": [], "symbol_candidates": [ - "RuntimeManager" + "RuntimeFactoryManager" ], "layers": [ "C1_SYMBOL_CATALOG", @@ -36,7 +36,7 @@ "step": "router", "status": "completed", "timings_ms": { - "router": 0 + "router": 2 }, "output": { "intent": "CODE_QA", @@ -49,13 +49,13 @@ "step": "retrieval", "status": "completed", "timings_ms": { - "retrieval": 194 + "retrieval": 145 }, "output": { "rag_count": 33, - "answer_path_rag_count": 33, - "resolved_symbol_status": "resolved", - "resolved_symbol": "RuntimeManager", + "answer_path_rag_count": 0, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, "requested_layers": [ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", @@ -108,48 +108,67 @@ "reason": null }, "retrieval_by_layer_ms": { - "C1_SYMBOL_CATALOG": 76, - "C0_SOURCE_CHUNKS": 20, - "C4_SEMANTIC_ROLES": 22, - "C2_DEPENDENCY_GRAPH": 62, - "C3_ENTRYPOINTS": 12 + "C1_SYMBOL_CATALOG": 32, + "C0_SOURCE_CHUNKS": 22, + "C4_SEMANTIC_ROLES": 18, + "C2_DEPENDENCY_GRAPH": 58, + "C3_ENTRYPOINTS": 13 } } }, { "step": "pre_evidence_gate", - "status": "passed", + "status": "blocked", "timings_ms": { - "pre_evidence_gate": 0 + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] }, "output": { - "passed": true, - "failure_reasons": [], - "degraded_message": "" + "passed": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "degraded_message": "Insufficient evidence for a confident answer. Evidence count: 0 (minimum required not met).", + "evidence_count": 0 } }, { "step": "llm", - "status": "completed", + "status": "skipped", "timings_ms": { - "llm": 1244 + "llm": 1 }, "output": { - "prompt_name": "code_qa_explain_answer", - "answer_preview": "Класс `RuntimeManager` находится в файле `src/app_runtime/core/runtime.py`. Конкретной реализации инициализации или подробного описания методов в предоставленном контексте не видно. Однако исходя из имеющихся признаков:\n\n1. Класс имеет ответственность за управление состоянием и конфигурацией runtime" + "reason": "policy_short_circuit", + "answer_mode": "not_found", + "decision_reason": "symbol_resolution_not_found", + "answer_policy_branch": "explain_not_found" } }, { "step": "post_evidence_gate", - "status": "passed", + "status": "skipped", "timings_ms": { - "post_evidence_gate": 0, - "repair": 0 + "post_evidence_gate": 1 + }, + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null }, "output": { - "passed": true, - "reasons": [], - "repair_used": false + "reason": "no_draft_answer" } } ] @@ -157,7 +176,7 @@ ## Diagnostics { "intent_correct": null, - "target_found": true, + "target_found": false, "layers_used": [ "C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", @@ -165,8 +184,11 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "retrieval_sufficient": true, - "answer_mode": "normal", + "retrieval_sufficient": false, + "answer_mode": "insufficient", + "resolved_target": null, + "answer_policy_branch": "explain_not_found", + "decision_reason": "symbol_resolution_not_found", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -181,11 +203,11 @@ "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS" ], - "symbol_resolution_status": "resolved" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", - "query": "Объясни как работает класс RuntimeManager", + "query": "Объясни класс RuntimeFactoryManager", "sub_intent": "EXPLAIN", "path_scope": [], "requested_layers": [ @@ -199,47 +221,79 @@ "per_layer_outcome": [ { "layer_id": "C1_SYMBOL_CATALOG", - "hit_count": 8, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 8, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C4_SEMANTIC_ROLES", - "hit_count": 8, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C2_DEPENDENCY_GRAPH", - "hit_count": 6, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false }, { "layer_id": "C3_ENTRYPOINTS", - "hit_count": 3, - "empty": false, + "hit_count": 0, + "empty": true, "fallback_used": false } ], - "empty_layers": [], + "empty_layers": [ + "C1_SYMBOL_CATALOG", + "C0_SOURCE_CHUNKS", + "C4_SEMANTIC_ROLES", + "C2_DEPENDENCY_GRAPH", + "C3_ENTRYPOINTS" + ], "evidence_gate_decision": { - "sufficient": true, - "failure_reasons": [], - "evidence_count": 33 + "sufficient": false, + "failure_reasons": [ + "insufficient_evidence" + ], + "evidence_count": 0 }, - "failure_reasons": [], + "evidence_gate_input": { + "resolved_target": null, + "sub_intent": "EXPLAIN", + "target_type": "none", + "evidence_count": 0, + "code_chunk_count": 0, + "entrypoint_count": 0, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "not_found", + "draft_present": false, + "resolved_target": null + }, + "output": { + "reason": "no_draft_answer" + } + }, + "failure_reasons": [ + "insufficient_evidence" + ], "timings_ms": { - "router": 0, - "retrieval": 194, - "pre_evidence_gate": 0, - "llm": 1244 + "router": 2, + "retrieval": 145, + "pre_evidence_gate": 1, + "post_evidence_gate": 1 } } diff --git a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.json similarity index 74% rename from tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json rename to tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.json index e4ae87b..830f94b 100644 --- a/tests/pipeline_setup_v3/test_results/plba_full_chain_subintents_v3/20260312_162842/full_chain_plba_code_subintents_v2_plba-v2-find-entrypoints-health-endpoint.json +++ b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.json @@ -1,6 +1,6 @@ { "case_id": "plba-v2-find-entrypoints-health-endpoint", - "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v2/cases/suite_02_pipeline/full_chain_plba_code_subintents_v2.yaml", + "source_file": "/Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml", "runner": "agent_runtime", "mode": "full_chain", "query": "Где health endpoint?", @@ -9,8 +9,8 @@ "sub_intent": "FIND_ENTRYPOINTS", "graph_id": "CodeQAGraph", "conversation_mode": "START", - "rag_count": 9, - "llm_answer": "health endpoint: \n- src/app_runtime/control/http_app.py:38-42 (app.post)\n- src/app_runtime/control/http_app.py:31-34 (app.get)", + "rag_count": 10, + "llm_answer": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", "answer_mode": "answered", "path_scope": [], "symbol_candidates": [ @@ -22,10 +22,8 @@ "C0_SOURCE_CHUNKS" ] }, - "passed": false, - "mismatches": [ - "llm: expected answer to contain 'GET /health'" - ], + "passed": true, + "mismatches": [], "details": { "query": "Где health endpoint?", "router_result": { @@ -122,12 +120,9 @@ } }, "symbol_resolution": { - "status": "pending", + "status": "not_found", "resolved_symbol": null, - "alternatives": [ - "health", - "endpoint" - ], + "alternatives": [], "confidence": 0.0 }, "evidence_policy": { @@ -491,28 +486,22 @@ "last_modified": null, "staleness_score": null } - } - ], - "relations": [], - "entrypoints": [ + }, { + "layer": "C0_SOURCE_CHUNKS", "path": "src/app_runtime/control/http_app.py", - "title": "app.post", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "start_line": 15, + "end_line": 53, "metadata": { - "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", - "entry_type": "http", - "framework": "fastapi", - "route_or_command": "app.post", - "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", "is_test": false, - "lang_payload": { - "methods": [ - "POST" - ] - }, - "artifact_type": null, "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", "repo_id": "plba", + "artifact_type": null, "section": null, "doc_id": null, "doc_version": null, @@ -521,10 +510,20 @@ "last_modified": null, "staleness_score": null } - }, + } + ], + "relations": [], + "entrypoints": [ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 31, + "end_line": 34, + "http_method": "GET", + "route_path": "/health", + "handler_symbol": "health", + "handler_symbol_id": "ab49f8d604dfed17bd83972a4158047a7c773c20ff58fbabc7963f4a1ec96834", + "route_or_command": "app.get", "metadata": { "entry_id": "5377b9336800b5d63cc3b67a58730d18a409b245650dd9449325d87c64e24f62", "entry_type": "http", @@ -552,6 +551,13 @@ { "path": "src/app_runtime/control/http_app.py", "title": "app.get", + "start_line": 38, + "end_line": 42, + "http_method": "GET", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.get", "metadata": { "entry_id": "06e2f03cced7c1146b2d29f81951f2a2839140484eae22b2d6a63075d903ca4a", "entry_type": "http", @@ -575,6 +581,40 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "title": "app.post", + "start_line": 38, + "end_line": 42, + "http_method": "POST", + "route_path": "/actions/{action}", + "handler_symbol": "action", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "route_or_command": "app.post", + "metadata": { + "entry_id": "56ed4b3229229e985cbf949d567b742b156412c7280eba9b5b54668f61bf0305", + "entry_type": "http", + "framework": "fastapi", + "route_or_command": "app.post", + "handler_symbol_id": "4da634384f08efb2d4cc12ac58ce1e667a780481392b4e715ae963e8e8a37fab", + "is_test": false, + "lang_payload": { + "methods": [ + "POST" + ] + }, + "artifact_type": null, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "test_candidates": [], @@ -587,7 +627,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -884,6 +924,36 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "retrieval_report": { @@ -893,18 +963,20 @@ ], "retrieval_mode_by_layer": { "C3_ENTRYPOINTS": "vector", - "C0_SOURCE_CHUNKS": "vector" + "C0_SOURCE_CHUNKS": "exact_path_fetch" }, "top_k_by_layer": { "C3_ENTRYPOINTS": 12, - "C0_SOURCE_CHUNKS": 6 + "C0_SOURCE_CHUNKS": 24 }, "filters_by_layer": { "C3_ENTRYPOINTS": { "path_scope": [] }, "C0_SOURCE_CHUNKS": { - "path_scope": [] + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] } }, "fallback": { @@ -912,9 +984,16 @@ "reason": null }, "retrieval_by_layer_ms": { - "C3_ENTRYPOINTS": 32, - "C0_SOURCE_CHUNKS": 19 - } + "C3_ENTRYPOINTS": 240, + "C0_SOURCE_CHUNKS": 9 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] } }, "diagnostics": { @@ -926,6 +1005,9 @@ ], "retrieval_sufficient": true, "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", "router_result": { "intent": "CODE_QA", "graph_id": "CodeQAGraph", @@ -937,7 +1019,7 @@ "C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS" ], - "symbol_resolution_status": "pending" + "symbol_resolution_status": "not_found" }, "retrieval_request": { "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", @@ -958,7 +1040,7 @@ }, { "layer_id": "C0_SOURCE_CHUNKS", - "hit_count": 6, + "hit_count": 7, "empty": false, "fallback_used": false } @@ -967,10 +1049,44 @@ "evidence_gate_decision": { "sufficient": true, "failure_reasons": [], - "evidence_count": 9 + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)" + } }, "failure_reasons": [], - "timings_ms": {} + "timings_ms": { + "router": 1, + "retrieval": 254, + "pre_evidence_gate": 1, + "llm": 3666, + "post_evidence_gate": 1 + } }, "rag_rows": [ { @@ -1263,12 +1379,175 @@ "last_modified": null, "staleness_score": null } + }, + { + "path": "src/app_runtime/control/http_app.py", + "content": "class HttpControlAppFactory:\n def create(\n self,\n health_provider: Callable[[], Awaitable[HealthPayload]],\n action_provider: Callable[[str, str], Awaitable[JSONResponse]],\n ) -> FastAPI:\n app = FastAPI(title=\"PLBA Control API\")\n\n @app.middleware(\"http\")\n async def log_api_call(request: Request, call_next): # type: ignore[no-untyped-def]\n started = time.monotonic()\n response = await call_next(request)\n response.headers[\"X-Response-Time-Ms\"] = str(int((time.monotonic() - started) * 1000))\n return response\n\n @app.get(\"/health\")\n async def health() -> JSONResponse:\n payload = await health_provider()\n status_code = 200 if payload.get(\"status\") == \"ok\" else 503\n return JSONResponse(content=payload, status_code=status_code)\n\n @app.get(\"/actions/{action}\")\n @app.post(\"/actions/{action}\")\n async def action(action: str, request: Request) -> JSONResponse:\n client_source = self._client_source(request)\n if action in {\"start\", \"stop\"}:\n LOGGER.warning(\"Control action requested: /actions/%s client=%s\", action, client_source)\n return await action_provider(action, client_source)\n\n return app\n\n def _client_source(self, request: Request) -> str:\n explicit_header = request.headers.get(\"X-Client-Source\", \"\").strip()\n if explicit_header:\n return explicit_header\n user_agent = request.headers.get(\"User-Agent\", \"\").strip()\n if user_agent:\n return f\"user-agent:{user_agent}\"\n return \"unknown\"", + "layer": "C0_SOURCE_CHUNKS", + "title": "src/app_runtime/control/http_app.py:HttpControlAppFactory", + "span_start": 15, + "span_end": 53, + "lexical_rank": 0, + "prefer_bonus": 0, + "test_penalty": 0, + "structural_rank": 0, + "layer_rank": 0, + "distance": 0, + "metadata": { + "chunk_index": 0, + "chunk_type": "symbol_block", + "module_or_unit": "src.app_runtime.control.http_app", + "is_test": false, + "blob_sha": "1cebc374b1999638635b2f2c2ccf1dcf11c465914c22dd9490b1531278846919", + "repo_id": "plba", + "artifact_type": null, + "section": null, + "doc_id": null, + "doc_version": null, + "owner": null, + "system_component": null, + "last_modified": null, + "staleness_score": null + } } ], "validation": { "passed": true, "action": "return", "reasons": [] - } + }, + "steps": [ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 254 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 240, + "C0_SOURCE_CHUNKS": 9 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3666 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)" + } + } + ] } } \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.md b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.md new file mode 100644 index 0000000..252b167 --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/full_chain_plba_quality_focus_plba-v2-find-entrypoints-health-endpoint.md @@ -0,0 +1,261 @@ +# plba-v2-find-entrypoints-health-endpoint + +- source_file: /Users/alex/Dev_projects_v2/ai driven app process/v2/agent/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml +- runner: agent_runtime +- mode: full_chain +- passed: True + +## Query +Где health endpoint? + +## Actual +{ + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "rag_count": 10, + "llm_answer": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "answer_mode": "answered", + "path_scope": [], + "symbol_candidates": [ + "health", + "endpoint" + ], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] +} + +## Steps +[ + { + "step": "router", + "status": "completed", + "timings_ms": { + "router": 1 + }, + "output": { + "intent": "CODE_QA", + "sub_intent": "FIND_ENTRYPOINTS", + "graph_id": "CodeQAGraph", + "conversation_mode": "START" + } + }, + { + "step": "retrieval", + "status": "completed", + "timings_ms": { + "retrieval": 254 + }, + "output": { + "rag_count": 10, + "answer_path_rag_count": 10, + "resolved_symbol_status": "not_found", + "resolved_symbol": null, + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "diagnostics": { + "executed_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_mode_by_layer": { + "C3_ENTRYPOINTS": "vector", + "C0_SOURCE_CHUNKS": "exact_path_fetch" + }, + "top_k_by_layer": { + "C3_ENTRYPOINTS": 12, + "C0_SOURCE_CHUNKS": 24 + }, + "filters_by_layer": { + "C3_ENTRYPOINTS": { + "path_scope": [] + }, + "C0_SOURCE_CHUNKS": { + "path_scope": [ + "src/app_runtime/control/http_app.py" + ] + } + }, + "fallback": { + "used": false, + "reason": null + }, + "retrieval_by_layer_ms": { + "C3_ENTRYPOINTS": 240, + "C0_SOURCE_CHUNKS": 9 + }, + "supplemental_requests": [ + { + "layer": "C0_SOURCE_CHUNKS", + "query": "Где health endpoint?", + "ranking_profile": "entrypoint_source_hydration" + } + ] + } + }, + { + "step": "pre_evidence_gate", + "status": "passed", + "timings_ms": { + "pre_evidence_gate": 1 + }, + "input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "output": { + "passed": true, + "failure_reasons": [], + "degraded_message": "", + "evidence_count": 10 + } + }, + { + "step": "llm", + "status": "completed", + "timings_ms": { + "llm": 3666 + }, + "output": { + "prompt_name": "code_qa_find_entrypoints_answer", + "answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient" + } + }, + { + "step": "post_evidence_gate", + "status": "passed", + "timings_ms": { + "post_evidence_gate": 1, + "post_evidence_gate_recheck": 0, + "repair": 0 + }, + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)" + } + } +] + +## Diagnostics +{ + "intent_correct": null, + "target_found": true, + "layers_used": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "retrieval_sufficient": true, + "answer_mode": "normal", + "resolved_target": "src/app_runtime/control/http_app.py", + "answer_policy_branch": "normal_answer", + "decision_reason": "evidence_sufficient", + "router_result": { + "intent": "CODE_QA", + "graph_id": "CodeQAGraph", + "conversation_mode": "START", + "retrieval_profile": "code", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ], + "symbol_resolution_status": "not_found" + }, + "retrieval_request": { + "rag_session_id": "7d11da21-faa0-4cea-aede-aeabe069164c", + "query": "Где health endpoint?", + "sub_intent": "FIND_ENTRYPOINTS", + "path_scope": [], + "requested_layers": [ + "C3_ENTRYPOINTS", + "C0_SOURCE_CHUNKS" + ] + }, + "per_layer_outcome": [ + { + "layer_id": "C3_ENTRYPOINTS", + "hit_count": 3, + "empty": false, + "fallback_used": false + }, + { + "layer_id": "C0_SOURCE_CHUNKS", + "hit_count": 7, + "empty": false, + "fallback_used": false + } + ], + "empty_layers": [], + "evidence_gate_decision": { + "sufficient": true, + "failure_reasons": [], + "evidence_count": 10 + }, + "evidence_gate_input": { + "resolved_target": "src/app_runtime/control/http_app.py", + "sub_intent": "FIND_ENTRYPOINTS", + "target_type": "file", + "evidence_count": 10, + "code_chunk_count": 10, + "entrypoint_count": 3, + "relation_count": 0, + "test_evidence_count": 0, + "symbol_resolution_status": "not_found", + "path_scope": [] + }, + "post_evidence_gate": { + "input": { + "answer_mode": "normal", + "degraded_message": "", + "resolved_target": "src/app_runtime/control/http_app.py", + "draft_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)", + "repair_candidate": true + }, + "output": { + "passed": true, + "action": "return", + "reasons": [], + "repair_used": false, + "final_answer_preview": "Конкретная точка health endpoint подтверждена:\n\n- GET /health (объявлен в src/app_runtime/control/http_app.py:31-34)\n\nДругие endpoints найдены, но не являются точками health:\n\n- POST /actions/{action}\n- GET /actions/{action} (эти маршруты объявлены там же, но не отмечены как health check)" + } + }, + "failure_reasons": [], + "timings_ms": { + "router": 1, + "retrieval": 254, + "pre_evidence_gate": 1, + "llm": 3666, + "post_evidence_gate": 1 + } +} + +## Mismatches +- none \ No newline at end of file diff --git a/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/summary.md b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/summary.md new file mode 100644 index 0000000..b4a62cb --- /dev/null +++ b/tests/pipeline_setup_v3/test_results/plba_quality_focus_v3/20260312_173122/summary.md @@ -0,0 +1,16 @@ +# pipeline_setup_v3 summary + +Passed: 2/2 + +| File | Case | Mode | Query | Actual sub-intent | RAG layers | Pass | +|------|------|------|-------|-------------------|------------|------| +| full_chain_plba_quality_focus.yaml | plba-v2-find-entrypoints-health-endpoint | full_chain | Где health endpoint? | FIND_ENTRYPOINTS | C0_SOURCE_CHUNKS:7, C3_ENTRYPOINTS:3 | ✓ | +| full_chain_plba_quality_focus.yaml | plba-v2-explain-nonexistent-symbol | full_chain | Объясни класс RuntimeFactoryManager | EXPLAIN | — | ✓ | + +## LLM Answers +- **plba-v2-find-entrypoints-health-endpoint** + Query: Где health endpoint? + > Конкретная точка health endpoint подтверждена: \- GET /health \(объявлен в src/app\_runtime/control/http\_app.py:31\-34\) Другие endpoints найдены, но не являются точками health: \- POST /actions/\{action\} \- GET /actions/\{action\} \(эти маршруты объявлены там же, но не отмечены как health check\) +- **plba-v2-explain-nonexistent-symbol** + Query: Объясни класс RuntimeFactoryManager + > Сущность RuntimeFactoryManager не найдена в доступном коде. \ No newline at end of file diff --git a/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml b/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml new file mode 100644 index 0000000..c56bd17 --- /dev/null +++ b/tests/pipeline_setup_v3/tmp/full_chain_plba_quality_focus.yaml @@ -0,0 +1,36 @@ +defaults: + runner: runtime + mode: full_chain + input: + rag_session_id: "7d11da21-faa0-4cea-aede-aeabe069164c" + +cases: + - id: plba-v2-find-entrypoints-health-endpoint + query: "Где health endpoint?" + expected: + router: + intent: CODE_QA + sub_intent: FIND_ENTRYPOINTS + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + non_empty: true + layers_include: ["C3_ENTRYPOINTS", "C0_SOURCE_CHUNKS"] + llm: + non_empty: true + contains_all: ["GET /health"] + excludes: ["не обнаружено"] + + - id: plba-v2-explain-nonexistent-symbol + query: "Объясни класс RuntimeFactoryManager" + expected: + router: + intent: CODE_QA + sub_intent: EXPLAIN + graph_id: CodeQAGraph + conversation_mode: START + retrieval: + layers_include: ["C1_SYMBOL_CATALOG", "C0_SOURCE_CHUNKS", "C2_DEPENDENCY_GRAPH", "C3_ENTRYPOINTS", "C4_SEMANTIC_ROLES"] + llm: + non_empty: true + contains_all: ["не найдена"]