From 1810a695d0a00ec00c90f1bb2d555359ea78060a Mon Sep 17 00:00:00 2001 From: tobjend Date: Mon, 13 Jul 2026 00:03:48 +0200 Subject: [PATCH] experiments: round 20 AST-migration verification across 3 languages Run RAGSAK (Kotlin), fastapi (Python), zod (TypeScript) with --slice package --min-structure 0.5, verbose+timeout, results saved for later. After _count_concat memoization fix: RAGSAK full run 54.9s -> 6.7s, no tail stalls. RAGSAK: 121 packages (28 with grammar). fastapi/zod complete in ~25s (dominated by arg-extraction on 2000+ method test groups, not grammar explosion). Includes SUMMARY.md with before/after. --- .../results/round20_ast_verify/fastapi.log | 294 + .../round20_ast_verify/fastapi_grammars.json | 33496 ++++++++++++++++ .../results/round20_ast_verify/ragsak.log | 264 + .../round20_ast_verify/ragsak_golden.json | 4338 ++ .../round20_ast_verify/ragsak_grammars.json | 4140 ++ .../results/round20_ast_verify/zod.log | 51 + .../round20_ast_verify/zod_grammars.json | 13348 ++++++ 7 files changed, 55931 insertions(+) create mode 100644 experiments/results/round20_ast_verify/fastapi.log create mode 100644 experiments/results/round20_ast_verify/fastapi_grammars.json create mode 100644 experiments/results/round20_ast_verify/ragsak.log create mode 100644 experiments/results/round20_ast_verify/ragsak_golden.json create mode 100644 experiments/results/round20_ast_verify/ragsak_grammars.json create mode 100644 experiments/results/round20_ast_verify/zod.log create mode 100644 experiments/results/round20_ast_verify/zod_grammars.json diff --git a/experiments/results/round20_ast_verify/fastapi.log b/experiments/results/round20_ast_verify/fastapi.log new file mode 100644 index 0000000..db8cf7b --- /dev/null +++ b/experiments/results/round20_ast_verify/fastapi.log @@ -0,0 +1,294 @@ +[ 0.0s] Scanning /home/tobi/Desktop/dervish/external_refs/fastapi ... +[ 0.0s] Preprocessing 4 files across 12 workers ... +[ 0.3s] Preprocess: 50 methods from 4 .js files (0.2s) +[ 0.3s] Groups: 1 named, 1 ungrouped methods +[ 0.3s] ├ docs/en/docs/js (49 methods) +[ 0.3s] └ (other) (1 methods) +[ 0.3s] Inferring 1 groups across 12 workers ... +[ 0.5s] [1/1] docs/en/docs/js (49 methods) done (0.2s) +[ 0.5s] Preprocessing 1129 files across 12 workers ... +[ 9.5s] Preprocess: 4811 methods from 1129 .py files (9.0s) +[ 9.5s] Groups: 141 named, 0 ungrouped methods +[ 9.5s] ├ docs_src (45 methods) +[ 9.5s] ├ docs_src/additional_responses (4 methods) +[ 9.5s] ├ docs_src/advanced_middleware (3 methods) +[ 9.5s] ├ docs_src/app_testing (14 methods) +[ 9.5s] ├ docs_src/app_testing/app_b_an_py310 (8 methods) +[ 9.5s] ├ docs_src/app_testing/app_b_py310 (8 methods) +[ 9.5s] ├ docs_src/background_tasks (8 methods) +[ 9.5s] ├ docs_src/behind_a_proxy (5 methods) +[ 9.5s] ├ docs_src/bigger_applications/app_an_py310 (4 methods) +[ 9.5s] ├ docs_src/bigger_applications/app_an_py310/routers (6 methods) +[ 9.5s] ├ docs_src/body (4 methods) +[ 9.5s] ├ docs_src/body_multiple_params (9 methods) +[ 9.5s] ├ docs_src/body_nested_models (9 methods) +[ 9.5s] ├ docs_src/body_updates (4 methods) +[ 9.5s] ├ docs_src/configure_swagger_ui (3 methods) +[ 9.5s] ├ docs_src/cookie_param_models (4 methods) +[ 9.5s] ├ docs_src/custom_docs_ui (8 methods) +[ 9.5s] ├ docs_src/custom_request_and_route (18 methods) +[ 9.5s] ├ docs_src/custom_response (19 methods) +[ 9.5s] ├ docs_src/dataclasses_ (4 methods) +[ 9.5s] ├ docs_src/dependencies (82 methods) +[ 9.5s] ├ docs_src/dependency_testing (14 methods) +[ 9.5s] ├ docs_src/events (7 methods) +[ 9.5s] ├ docs_src/extra_models (9 methods) +[ 9.5s] ├ docs_src/generate_clients (9 methods) +[ 9.5s] ├ docs_src/handling_errors (13 methods) +[ 9.5s] ├ docs_src/header_param_models (6 methods) +[ 9.5s] ├ docs_src/header_params (6 methods) +[ 9.5s] ├ docs_src/json_base64_bytes (3 methods) +[ 9.5s] ├ docs_src/metadata (6 methods) +[ 9.5s] ├ docs_src/path_operation_advanced_configuration (9 methods) +[ 9.5s] ├ docs_src/path_operation_configuration (12 methods) +[ 9.5s] ├ docs_src/path_params (8 methods) +[ 9.5s] ├ docs_src/path_params_numeric_validations (12 methods) +[ 9.5s] ├ docs_src/pydantic_v1_in_v2 (3 methods) +[ 9.5s] ├ docs_src/python_types (13 methods) +[ 9.5s] ├ docs_src/query_param_models (4 methods) +[ 9.5s] ├ docs_src/query_params (6 methods) +[ 9.5s] ├ docs_src/query_params_str_validations (31 methods) +[ 9.5s] ├ docs_src/request_files (24 methods) +[ 9.5s] ├ docs_src/request_form_models (4 methods) +[ 9.5s] ├ docs_src/response_model (16 methods) +[ 9.5s] ├ docs_src/schema_extra_example (8 methods) +[ 9.5s] ├ docs_src/security (70 methods) +[ 9.5s] ├ docs_src/separate_openapi_schemas (4 methods) +[ 9.5s] ├ docs_src/server_sent_events (8 methods) +[ 9.5s] ├ docs_src/settings (5 methods) +[ 9.5s] ├ docs_src/settings/app02_an_py310 (4 methods) +[ 9.5s] ├ docs_src/settings/app02_py310 (4 methods) +[ 9.5s] ├ docs_src/sql_databases (30 methods) +[ 9.5s] ├ docs_src/stream_data (14 methods) +[ 9.5s] ├ docs_src/stream_json_lines (4 methods) +[ 9.5s] ├ docs_src/websockets_ (15 methods) +[ 9.5s] ├ fastapi (239 methods) +[ 9.5s] ├ fastapi/_compat (45 methods) +[ 9.5s] ├ fastapi/dependencies (38 methods) +[ 9.5s] ├ fastapi/openapi (19 methods) +[ 9.5s] ├ fastapi/security (34 methods) +[ 9.5s] ├ scripts (132 methods) +[ 9.5s] ├ scripts/playwright (7 methods) +[ 9.5s] ├ scripts/playwright/separate_openapi_schemas (5 methods) +[ 9.5s] ├ scripts/tests/test_translation_fixer (12 methods) +[ 9.5s] ├ scripts/tests/test_translation_fixer/test_code_blocks (8 methods) +[ 9.5s] ├ scripts/tests/test_translation_fixer/test_header_permalinks (4 methods) +[ 9.5s] ├ tests (2036 methods) +[ 9.5s] ├ tests/benchmarks (48 methods) +[ 9.5s] ├ tests/test_modules_same_name_body (5 methods) +[ 9.5s] ├ tests/test_request_params/test_body (113 methods) +[ 9.5s] ├ tests/test_request_params/test_cookie (48 methods) +[ 9.5s] ├ tests/test_request_params/test_file (97 methods) +[ 9.5s] ├ tests/test_request_params/test_form (97 methods) +[ 9.5s] ├ tests/test_request_params/test_header (96 methods) +[ 9.5s] ├ tests/test_request_params/test_path (6 methods) +[ 9.5s] ├ tests/test_request_params/test_query (96 methods) +[ 9.5s] ├ tests/test_tutorial (16 methods) +[ 9.5s] ├ tests/test_tutorial/test_additional_responses (14 methods) +[ 9.5s] ├ tests/test_tutorial/test_additional_status_codes (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_advanced_middleware (4 methods) +[ 9.5s] ├ tests/test_tutorial/test_authentication_error_status_code (4 methods) +[ 9.5s] ├ tests/test_tutorial/test_background_tasks (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_behind_a_proxy (10 methods) +[ 9.5s] ├ tests/test_tutorial/test_bigger_applications (26 methods) +[ 9.5s] ├ tests/test_tutorial/test_body (32 methods) +[ 9.5s] ├ tests/test_tutorial/test_body_fields (5 methods) +[ 9.5s] ├ tests/test_tutorial/test_body_multiple_params (35 methods) +[ 9.5s] ├ tests/test_tutorial/test_body_nested_models (44 methods) +[ 9.5s] ├ tests/test_tutorial/test_body_updates (9 methods) +[ 9.5s] ├ tests/test_tutorial/test_conditional_openapi (4 methods) +[ 9.5s] ├ tests/test_tutorial/test_configure_swagger_ui (6 methods) +[ 9.5s] ├ tests/test_tutorial/test_cookie_param_models (12 methods) +[ 9.5s] ├ tests/test_tutorial/test_cookie_params (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_custom_docs_ui (10 methods) +[ 9.5s] ├ tests/test_tutorial/test_custom_request_and_route (10 methods) +[ 9.5s] ├ tests/test_tutorial/test_custom_response (25 methods) +[ 9.5s] ├ tests/test_tutorial/test_dataclasses (11 methods) +[ 9.5s] ├ tests/test_tutorial/test_debugging (5 methods) +[ 9.5s] ├ tests/test_tutorial/test_dependencies (51 methods) +[ 9.5s] ├ tests/test_tutorial/test_encoder (5 methods) +[ 9.5s] ├ tests/test_tutorial/test_events (8 methods) +[ 9.5s] ├ tests/test_tutorial/test_extra_data_types (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_extra_models (13 methods) +[ 9.5s] ├ tests/test_tutorial/test_first_steps (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_generate_clients (13 methods) +[ 9.5s] ├ tests/test_tutorial/test_graphql (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_handling_errors (20 methods) +[ 9.5s] ├ tests/test_tutorial/test_header_param_models (19 methods) +[ 9.5s] ├ tests/test_tutorial/test_header_params (9 methods) +[ 9.5s] ├ tests/test_tutorial/test_json_base64_bytes (5 methods) +[ 9.5s] ├ tests/test_tutorial/test_metadata (14 methods) +[ 9.5s] ├ tests/test_tutorial/test_openapi_callbacks (5 methods) +[ 9.5s] ├ tests/test_tutorial/test_openapi_webhooks (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_path_operation_advanced_configurations (18 methods) +[ 9.5s] ├ tests/test_tutorial/test_path_operation_configurations (20 methods) +[ 9.5s] ├ tests/test_tutorial/test_path_params (18 methods) +[ 9.5s] ├ tests/test_tutorial/test_path_params_numeric_validations (29 methods) +[ 9.5s] ├ tests/test_tutorial/test_python_types (15 methods) +[ 9.5s] ├ tests/test_tutorial/test_query_param_models (12 methods) +[ 9.5s] ├ tests/test_tutorial/test_query_params (19 methods) +[ 9.5s] ├ tests/test_tutorial/test_query_params_str_validations (81 methods) +[ 9.5s] ├ tests/test_tutorial/test_request_files (31 methods) +[ 9.5s] ├ tests/test_tutorial/test_request_form_models (15 methods) +[ 9.5s] ├ tests/test_tutorial/test_request_forms (7 methods) +[ 9.5s] ├ tests/test_tutorial/test_request_forms_and_files (8 methods) +[ 9.5s] ├ tests/test_tutorial/test_response_directly (6 methods) +[ 9.5s] ├ tests/test_tutorial/test_response_model (35 methods) +[ 9.5s] ├ tests/test_tutorial/test_response_status_code (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_schema_extra_example (15 methods) +[ 9.5s] ├ tests/test_tutorial/test_security (73 methods) +[ 9.5s] ├ tests/test_tutorial/test_separate_openapi_schemas (8 methods) +[ 9.5s] ├ tests/test_tutorial/test_server_sent_events (17 methods) +[ 9.5s] ├ tests/test_tutorial/test_settings (16 methods) +[ 9.5s] ├ tests/test_tutorial/test_sql_databases (8 methods) +[ 9.5s] ├ tests/test_tutorial/test_static_files (4 methods) +[ 9.5s] ├ tests/test_tutorial/test_stream_data (7 methods) +[ 9.5s] ├ tests/test_tutorial/test_stream_json_lines (3 methods) +[ 9.5s] ├ tests/test_tutorial/test_strict_content_type (4 methods) +[ 9.5s] ├ tests/test_tutorial/test_sub_applications (4 methods) +[ 9.5s] ├ tests/test_tutorial/test_testing (10 methods) +[ 9.5s] ├ tests/test_tutorial/test_testing_dependencies (8 methods) +[ 9.5s] ├ tests/test_tutorial/test_websockets (14 methods) +[ 9.5s] ├ tests/test_validate_response_recursive (3 methods) +[ 9.5s] Inferring 141 groups across 12 workers ... +[ 9.8s] [1/141] docs_src/additional_responses (4 methods) done (0.3s) +[ 9.9s] [2/141] docs_src/advanced_middleware (3 methods) done (0.4s) +[ 10.0s] [3/141] docs_src/bigger_applications/app_an_py310 (4 methods) done (0.5s) +[ 10.1s] [4/141] docs_src/body_updates (4 methods) done (0.6s) +[ 10.2s] [5/141] docs_src/bigger_applications/app_an_py310/routers (6 methods) done (0.7s) +[ 10.2s] [6/141] docs_src/app_testing (14 methods) done (0.7s) +[ 10.2s] [7/141] docs_src/app_testing/app_b_py310 (8 methods) done (0.7s) +[ 10.3s] [8/141] docs_src/app_testing/app_b_an_py310 (8 methods) done (0.8s) +[ 10.3s] [9/141] docs_src/cookie_param_models (4 methods) done (0.8s) +[ 10.3s] [10/141] docs_src/configure_swagger_ui (3 methods) done (0.8s) +[ 10.4s] [11/141] docs_src/background_tasks (8 methods) done (0.9s) +[ 10.5s] [12/141] docs_src/body (4 methods) done (1.0s) +[ 10.5s] [13/141] docs_src/custom_docs_ui (8 methods) done (1.0s) +[ 10.6s] [14/141] docs_src/dependency_testing (14 methods) done (1.0s) +[ 10.7s] [15/141] docs_src/behind_a_proxy (5 methods) done (1.2s) +[ 10.7s] [16/141] docs_src/dataclasses_ (4 methods) done (1.2s) +[ 10.7s] [17/141] docs_src/events (7 methods) done (1.2s) +[ 10.8s] [18/141] docs_src/json_base64_bytes (3 methods) done (1.3s) +[ 10.9s] [19/141] docs_src/custom_request_and_route (18 methods) done (1.3s) +[ 10.9s] [20/141] docs_src/generate_clients (9 methods) done (1.4s) +[ 11.0s] [21/141] docs_src/handling_errors (13 methods) done (1.5s) +[ 11.2s] [22/141] docs_src/body_nested_models (9 methods) done (1.7s) +[ 11.2s] [23/141] docs_src/body_multiple_params (9 methods) done (1.7s) +[ 11.3s] [24/141] docs_src/metadata (6 methods) done (1.8s) +[ 11.4s] [25/141] docs_src/extra_models (9 methods) done (1.9s) +[ 11.4s] [26/141] docs_src/header_params (6 methods) done (1.9s) +[ 11.4s] [27/141] docs_src/path_operation_advanced_configuration (9 methods) done (1.9s) +[ 11.6s] [28/141] docs_src/custom_response (19 methods) done (2.1s) +[ 11.7s] [29/141] docs_src/path_operation_configuration (12 methods) done (2.2s) +[ 11.8s] [30/141] docs_src (45 methods) done (2.3s) +[ 11.8s] [31/141] docs_src/path_params (8 methods) done (2.3s) +[ 12.0s] [32/141] docs_src/header_param_models (6 methods) done (2.4s) +[ 12.0s] [33/141] docs_src/pydantic_v1_in_v2 (3 methods) done (2.4s) +[ 12.1s] [34/141] docs_src/request_form_models (4 methods) done (2.6s) +[ 12.4s] [35/141] docs_src/query_param_models (4 methods) done (2.9s) +[ 12.4s] [36/141] docs_src/separate_openapi_schemas (4 methods) done (2.9s) +[ 12.6s] [37/141] docs_src/server_sent_events (8 methods) done (3.0s) +[ 12.7s] [38/141] docs_src/settings/app02_py310 (4 methods) done (3.2s) +[ 12.7s] [39/141] docs_src/response_model (16 methods) done (3.2s) +[ 12.7s] [40/141] docs_src/query_params (6 methods) done (3.2s) +[ 12.8s] [41/141] docs_src/settings (5 methods) done (3.3s) +[ 12.9s] [42/141] docs_src/settings/app02_an_py310 (4 methods) done (3.3s) +[ 12.9s] [43/141] docs_src/stream_data (14 methods) done (3.4s) +[ 13.0s] [44/141] docs_src/schema_extra_example (8 methods) done (3.5s) +[ 13.0s] [45/141] docs_src/request_files (24 methods) done (3.5s) +[ 13.0s] [46/141] docs_src/stream_json_lines (4 methods) done (3.5s) +[ 13.1s] [47/141] docs_src/sql_databases (30 methods) done (3.5s) +[ 13.3s] [48/141] fastapi/_compat (45 methods) done (3.8s) +[ 13.4s] [49/141] fastapi/openapi (19 methods) done (3.9s) +[ 13.5s] [50/141] fastapi/dependencies (38 methods) done (3.9s) +[ 13.6s] [51/141] docs_src/websockets_ (15 methods) done (4.1s) +[ 13.7s] [52/141] docs_src/python_types (13 methods) done (4.1s) +[ 13.7s] [53/141] docs_src/path_params_numeric_validations (12 methods) done (4.2s) +[ 13.9s] [54/141] scripts/playwright/separate_openapi_schemas (5 methods) done (4.3s) +[ 14.0s] [55/141] tests/benchmarks (48 methods) done (4.5s) +[ 14.1s] [56/141] scripts (132 methods) done (4.6s) +[ 14.2s] [57/141] scripts/tests/test_translation_fixer/test_header_permalinks (4 methods) done (4.7s) +[ 14.3s] [58/141] tests/test_modules_same_name_body (5 methods) done (4.8s) +[ 14.5s] [59/141] scripts/tests/test_translation_fixer/test_code_blocks (8 methods) done (5.0s) +[ 14.6s] [60/141] tests/test_request_params/test_body (113 methods) done (5.1s) +[ 14.8s] [61/141] docs_src/query_params_str_validations (31 methods) done (5.2s) +[ 14.9s] [62/141] tests/test_request_params/test_path (6 methods) done (5.3s) +[ 14.9s] [63/141] tests/test_request_params/test_file (97 methods) done (5.4s) +[ 14.9s] [64/141] tests/test_request_params/test_cookie (48 methods) done (5.4s) +[ 14.9s] [65/141] scripts/tests/test_translation_fixer (12 methods) done (5.4s) +[ 15.0s] [66/141] tests/test_request_params/test_header (96 methods) done (5.5s) +[ 15.2s] [67/141] tests/test_tutorial/test_additional_status_codes (3 methods) done (5.7s) +[ 15.2s] [68/141] tests/test_tutorial/test_advanced_middleware (4 methods) done (5.7s) +[ 15.3s] [69/141] tests/test_request_params/test_query (96 methods) done (5.7s) +[ 15.4s] [70/141] tests/test_tutorial/test_authentication_error_status_code (4 methods) done (5.8s) +[ 15.5s] [71/141] tests/test_tutorial/test_background_tasks (3 methods) done (5.9s) +[ 15.6s] [72/141] tests/test_tutorial/test_additional_responses (14 methods) done (6.0s) +[ 15.6s] [73/141] scripts/playwright (7 methods) done (6.1s) +[ 15.6s] [74/141] tests/test_request_params/test_form (97 methods) done (6.1s) +[ 15.7s] [75/141] tests/test_tutorial/test_body_fields (5 methods) done (6.2s) +[ 15.7s] [76/141] tests/test_tutorial/test_bigger_applications (26 methods) done (6.2s) +[ 15.8s] [77/141] tests/test_tutorial/test_body (32 methods) done (6.3s) +[ 15.8s] [78/141] docs_src/dependencies (82 methods) done (6.3s) +[ 15.9s] [79/141] tests/test_tutorial/test_conditional_openapi (4 methods) done (6.4s) +[ 15.9s] [80/141] docs_src/security (70 methods) done (6.4s) +[ 16.0s] [81/141] tests/test_tutorial/test_behind_a_proxy (10 methods) done (6.4s) +[ 16.0s] [82/141] tests/test_tutorial (16 methods) done (6.4s) +[ 16.0s] [83/141] tests/test_tutorial/test_configure_swagger_ui (6 methods) done (6.5s) +[ 16.0s] [84/141] tests/test_tutorial/test_cookie_params (3 methods) done (6.5s) +[ 16.1s] [85/141] tests/test_tutorial/test_debugging (5 methods) done (6.6s) +[ 16.1s] [86/141] tests/test_tutorial/test_body_updates (9 methods) done (6.6s) +[ 16.1s] [87/141] tests/test_tutorial/test_body_multiple_params (35 methods) done (6.6s) +[ 16.2s] [88/141] tests/test_tutorial/test_dataclasses (11 methods) done (6.7s) +[ 16.3s] [89/141] fastapi/security (34 methods) done (6.7s) +[ 16.3s] [90/141] tests/test_tutorial/test_custom_request_and_route (10 methods) done (6.8s) +[ 16.3s] [91/141] tests/test_tutorial/test_encoder (5 methods) done (6.8s) +[ 16.3s] [92/141] tests/test_tutorial/test_cookie_param_models (12 methods) done (6.8s) +[ 16.3s] [93/141] tests/test_tutorial/test_extra_data_types (3 methods) done (6.8s) +[ 16.4s] [94/141] tests/test_tutorial/test_custom_docs_ui (10 methods) done (6.8s) +[ 16.4s] [95/141] tests/test_tutorial/test_first_steps (3 methods) done (6.9s) +[ 16.5s] [96/141] tests/test_tutorial/test_graphql (3 methods) done (7.0s) +[ 16.6s] [97/141] tests/test_tutorial/test_body_nested_models (44 methods) done (7.0s) +[ 16.6s] [98/141] tests/test_tutorial/test_events (8 methods) done (7.1s) +[ 16.7s] [99/141] tests/test_tutorial/test_openapi_callbacks (5 methods) done (7.1s) +[ 16.7s] [100/141] tests/test_tutorial/test_header_param_models (19 methods) done (7.1s) +[ 16.8s] [101/141] tests/test_tutorial/test_openapi_webhooks (3 methods) done (7.2s) +[ 16.8s] [102/141] tests/test_tutorial/test_handling_errors (20 methods) done (7.2s) +[ 16.8s] [103/141] tests/test_tutorial/test_json_base64_bytes (5 methods) done (7.3s) +[ 16.9s] [104/141] tests/test_tutorial/test_header_params (9 methods) done (7.4s) +[ 17.0s] [105/141] tests/test_tutorial/test_extra_models (13 methods) done (7.5s) +[ 17.0s] [106/141] tests/test_tutorial/test_generate_clients (13 methods) done (7.5s) +[ 17.2s] [107/141] tests/test_tutorial/test_path_params (18 methods) done (7.7s) +[ 17.3s] [108/141] tests/test_tutorial/test_path_operation_advanced_configurations (18 methods) done (7.7s) +[ 17.3s] [109/141] tests/test_tutorial/test_custom_response (25 methods) done (7.8s) +[ 17.3s] [110/141] tests/test_tutorial/test_metadata (14 methods) done (7.8s) +[ 17.4s] [111/141] tests/test_tutorial/test_path_params_numeric_validations (29 methods) done (7.9s) +[ 17.4s] [112/141] tests/test_tutorial/test_request_forms (7 methods) done (7.9s) +[ 17.5s] [113/141] tests/test_tutorial/test_request_form_models (15 methods) done (7.9s) +[ 17.5s] [114/141] tests/test_tutorial/test_query_param_models (12 methods) done (8.0s) +[ 17.5s] [115/141] tests/test_tutorial/test_request_forms_and_files (8 methods) done (8.0s) +[ 17.6s] [116/141] tests/test_tutorial/test_response_directly (6 methods) done (8.0s) +[ 17.6s] [117/141] tests/test_tutorial/test_response_status_code (3 methods) done (8.1s) +[ 17.7s] [118/141] tests/test_tutorial/test_path_operation_configurations (20 methods) done (8.2s) +[ 17.7s] [119/141] tests/test_tutorial/test_dependencies (51 methods) done (8.2s) +[ 17.8s] [120/141] tests/test_tutorial/test_request_files (31 methods) done (8.3s) +[ 17.9s] [121/141] tests/test_tutorial/test_schema_extra_example (15 methods) done (8.4s) +[ 18.0s] [122/141] tests/test_tutorial/test_static_files (4 methods) done (8.5s) +[ 18.0s] [123/141] tests/test_tutorial/test_separate_openapi_schemas (8 methods) done (8.5s) +[ 18.1s] [124/141] tests/test_tutorial/test_stream_data (7 methods) done (8.6s) +[ 18.2s] [125/141] tests/test_tutorial/test_stream_json_lines (3 methods) done (8.6s) +[ 18.2s] [126/141] tests/test_tutorial/test_python_types (15 methods) done (8.6s) +[ 18.2s] [127/141] tests/test_tutorial/test_strict_content_type (4 methods) done (8.7s) +[ 18.2s] [128/141] tests/test_tutorial/test_query_params (19 methods) done (8.7s) +[ 18.2s] [129/141] tests/test_tutorial/test_security (73 methods) done (8.7s) +[ 18.3s] [130/141] tests/test_tutorial/test_sub_applications (4 methods) done (8.7s) +[ 18.3s] [131/141] tests/test_tutorial/test_testing_dependencies (8 methods) done (8.8s) +[ 18.3s] [132/141] tests/test_tutorial/test_sql_databases (8 methods) done (8.8s) +[ 18.4s] [133/141] tests/test_tutorial/test_query_params_str_validations (81 methods) done (8.9s) +[ 18.5s] [134/141] tests/test_validate_response_recursive (3 methods) done (8.9s) +[ 18.6s] [135/141] tests/test_tutorial/test_settings (16 methods) done (9.0s) +[ 18.6s] [136/141] tests/test_tutorial/test_response_model (35 methods) done (9.1s) +[ 18.6s] [137/141] tests/test_tutorial/test_server_sent_events (17 methods) done (9.1s) +[ 18.7s] [138/141] tests/test_tutorial/test_testing (10 methods) done (9.2s) +[ 18.7s] [139/141] tests/test_tutorial/test_websockets (14 methods) done (9.2s) +[ 19.7s] [140/141] fastapi (239 methods) done (10.2s) +[ 26.7s] [141/141] tests (2036 methods) done (17.2s) diff --git a/experiments/results/round20_ast_verify/fastapi_grammars.json b/experiments/results/round20_ast_verify/fastapi_grammars.json new file mode 100644 index 0000000..cc78c34 --- /dev/null +++ b/experiments/results/round20_ast_verify/fastapi_grammars.json @@ -0,0 +1,33496 @@ +[ + { + "language": ".js", + "conventions": [ + { + "label": "docs/en/docs/js", + "method_count": 49, + "imports": [], + "arg_patterns": { + "parseFloat": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "Termynal": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "getComputedStyle": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "setTimeout": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Promise": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "new": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "shuffle": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "saveBuffer": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "handleSponsorImages": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "setupTermynal": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "createTermynals": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "resolve": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "URL": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "openLinksInNewTab": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "loadVisibleTermynals": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "setInterval": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "setupOpinionsTabs": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "activate": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "showRandomAnnouncement": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "main": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "announceRandom": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "reject": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "(other)", + "method_count": 1, + "imports": [], + "arg_patterns": {} + } + ], + "total_methods": 50 + }, + { + "language": ".py", + "conventions": [ + { + "label": "docs_src", + "method_count": 45, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? (\"HTTP_201_CREATED\" | \"JSONResponse\" | \"app\" | \"await\" | \"content\" | \"duration\" | \"else\" | \"end_datetime\" | \"get\" | \"headers\" | \"id\" | \"in\" | \"item\" | \"item_id\" | \"items\" | \"json_compatible_item_data\" | \"jsonable_encoder\" | \"key\" | \"name\" | \"process_after\" | \"repeat_at\" | \"request\" | \"response\" | \"results\" | \"return\" | \"set_cookie\" | \"size\" | \"start_datetime\" | \"start_process\" | \"status\" | \"status_code\" | \"value\")+ \"len\"?+ (\"ads_id\" | \"username\")? \"file\"? \"token\"? \"fileb\"? \"content_type\"?", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import Body, FastAPI, status", + "from fastapi.responses import JSONResponse", + "from fastapi import FastAPI", + "import pytest", + "from httpx import ASGITransport, AsyncClient", + "from .main import app", + "from fastapi import Depends, FastAPI, HTTPException, status", + "from fastapi.security import HTTPAuthorizationCredentials, HTTPBearer", + "from fastapi import Body, FastAPI", + "from pydantic import BaseModel, Field", + "from pydantic_settings import BaseSettings", + "from fastapi import Cookie, FastAPI", + "from fastapi.middleware.cors import CORSMiddleware", + "import uvicorn", + "from datetime import datetime", + "from fastapi.encoders import jsonable_encoder", + "from pydantic import BaseModel", + "from fastapi.openapi.utils import get_openapi", + "from datetime import datetime, time, timedelta", + "from uuid import UUID", + "import strawberry", + "from strawberry.fastapi import GraphQLRouter", + "import time", + "from fastapi import FastAPI, Request", + "from fastapi import APIRouter, FastAPI", + "from pydantic import BaseModel, HttpUrl", + "from fastapi import FastAPI, Form", + "from fastapi import FastAPI, File, Form, UploadFile", + "from fastapi import FastAPI, Response, status", + "from fastapi import FastAPI, Response", + "from fastapi import FastAPI, status", + "from fastapi.responses import HTMLResponse", + "from fastapi.staticfiles import StaticFiles", + "from fastapi.templating import Jinja2Templates", + "from a2wsgi import WSGIMiddleware", + "from flask import Flask, request", + "from markupsafe import escape" + ], + "arg_patterns": { + "Body": { + "occurrences": 42, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 27, + "args": 0, + "types": [] + }, + { + "count": 15, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "JSONResponse": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 123, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 117, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "get_openapi": { + "occurrences": 3, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "StaticFiles": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Jinja2Templates": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Cookie": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Form": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "File": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "len": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ASGITransport": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "AsyncClient": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "APIRouter": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Invoice": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "InvoiceEvent": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "InvoiceEventReceived": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Subscription": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Item": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Settings": { + "occurrences": 8, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "jsonable_encoder": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Field": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "Flask": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "escape": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "WSGIMiddleware": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Response": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "GraphQLRouter": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "User": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "str": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "call_next": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBearer403": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPException": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Depends": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + } + } + }, + { + "label": "docs_src/additional_responses", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"if\" (\"img\" | \"item_id\") (\"FileResponse\" | \"else\" | \"media_type\" | \"return\")+ \"JSONResponse\"?+ \"status_code\"? \"content\"?", + "mdl_score": 119424, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.responses import JSONResponse", + "from pydantic import BaseModel", + "from fastapi.responses import FileResponse" + ], + "arg_patterns": { + "JSONResponse": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Message": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FileResponse": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/advanced_middleware", + "method_count": 3, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.middleware.httpsredirect import HTTPSRedirectMiddleware", + "from fastapi.middleware.trustedhost import TrustedHostMiddleware", + "from fastapi.middleware.gzip import GZipMiddleware" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/app_testing", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= \"return\"? (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"items\" | \"json\" | \"response\" | \"status_code\" | \"yield\")?+ \"websocket_connect\"?+ (\"clear\" | \"item_id\")?+ (\"accept\" | \"await\" | \"data\" | \"receive_json\" | \"send_json\" | \"websocket\")?+ \"close\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.testclient import TestClient", + "from .main import app", + "from fastapi.websockets import WebSocket", + "from contextlib import asynccontextmanager" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/app_testing/app_b_an_py310", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"HTTPException\" | \"client\" | \"detail\" | \"fake_db\" | \"fake_secret_token\" | \"get\" | \"headers\" | \"id\" | \"if\" | \"in\" | \"item\" | \"item_id\" | \"json\" | \"model_dump\" | \"not\" | \"not in\" | \"post\" | \"raise\" | \"response\" | \"return\" | \"status_code\" | \"x_token\")+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, Header, HTTPException", + "from pydantic import BaseModel", + "from fastapi.testclient import TestClient", + "from .main import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Header": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "HTTPException": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/app_testing/app_b_py310", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"HTTPException\" | \"client\" | \"detail\" | \"fake_db\" | \"fake_secret_token\" | \"get\" | \"headers\" | \"id\" | \"if\" | \"in\" | \"item\" | \"item_id\" | \"json\" | \"model_dump\" | \"not\" | \"not in\" | \"post\" | \"raise\" | \"response\" | \"return\" | \"status_code\" | \"x_token\")+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI, Header, HTTPException", + "from pydantic import BaseModel", + "from fastapi.testclient import TestClient", + "from .main import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPException": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Header": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Item": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/background_tasks", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? \"open\"?+ \"mode\"? \"log\"?+ (\"add_task\" | \"background_tasks\" | \"content\" | \"email\" | \"email_file\" | \"message\" | \"q\" | \"return\" | \"write\" | \"write_log\" | \"write_notification\")+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import BackgroundTasks, FastAPI", + "from typing import Annotated", + "from fastapi import BackgroundTasks, Depends, FastAPI" + ], + "arg_patterns": { + "open": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "Depends": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/behind_a_proxy", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"request\"? \"scope\"? \"get\"?+", + "mdl_score": 16, + "imports": [ + "from fastapi import FastAPI", + "from fastapi import FastAPI, Request" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 3, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/bigger_applications/app_an_py310", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? \"return\"? (\"token\" | \"x_token\")? \"raise\"? \"HTTPException\"?+ \"status_code\"? \"detail\"?", + "mdl_score": 194, + "imports": [ + "from typing import Annotated", + "from fastapi import Header, HTTPException", + "from fastapi import APIRouter", + "from fastapi import Depends, FastAPI", + "from .dependencies import get_query_token, get_token_header", + "from .internal import admin", + "from .routers import items, users" + ], + "arg_patterns": { + "Header": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "HTTPException": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "APIRouter": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Depends": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/bigger_applications/app_an_py310/routers", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? (\"HTTPException\" | \"detail\" | \"fake_items_db\" | \"in\" | \"item_id\" | \"not\" | \"not in\" | \"raise\" | \"return\" | \"status_code\")+ \"username\"?", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import APIRouter, Depends, HTTPException", + "from ..dependencies import get_token_header", + "from fastapi import APIRouter" + ], + "arg_patterns": { + "APIRouter": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 4, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "HTTPException": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Depends": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/body", + "method_count": 4, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Item": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/body_multiple_params", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"if\" | \"importance\" | \"item\" | \"item_id\" | \"q\" | \"results\" | \"return\" | \"update\" | \"user\")+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, Path", + "from pydantic import BaseModel", + "from fastapi import FastAPI", + "from fastapi import Body, FastAPI" + ], + "arg_patterns": { + "Item": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Body": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "FastAPI": { + "occurrences": 27, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 27, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 14, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 14, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "User": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Path": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/body_nested_models", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"item\" | \"item_id\" | \"results\" | \"return\")+ (\"images\" | \"offer\" | \"weights\")?", + "mdl_score": 10836, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel", + "from pydantic import BaseModel, HttpUrl" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 27, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 27, + "args": 0, + "types": [] + } + ] + }, + "set": { + "occurrences": 25, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 25, + "args": 0, + "types": [] + } + ] + }, + "Item": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 7, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 13, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 13, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Image": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Offer": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/body_updates", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= (\"Item\" | \"exclude_unset\" | \"item\" | \"item_id\" | \"items\" | \"jsonable_encoder\" | \"model_copy\" | \"model_dump\" | \"return\" | \"stored_item_data\" | \"stored_item_model\" | \"update\" | \"update_data\" | \"update_item_encoded\" | \"updated_item\")+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.encoders import jsonable_encoder", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Item": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "jsonable_encoder": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/configure_swagger_ui", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"username\"", + "mdl_score": 3, + "imports": [ + "from fastapi import FastAPI" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/cookie_param_models", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"cookies\"", + "mdl_score": 4, + "imports": [ + "from typing import Annotated", + "from fastapi import Cookie, FastAPI", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Cookie": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Cookies": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/custom_docs_ui", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"return\" (\"get_redoc_html\" | \"get_swagger_ui_html\")?+ (\"get_swagger_ui_oauth2_redirect_html\" | \"username\")?+ (\"app\" | \"oauth2_redirect_url\" | \"openapi_url\" | \"title\")?+ \"swagger_ui_oauth2_redirect_url\"? \"redoc_js_url\"? \"swagger_js_url\"? \"swagger_css_url\"?", + "mdl_score": 1311457824, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.openapi.docs import (", + "from fastapi.staticfiles import StaticFiles" + ], + "arg_patterns": { + "get_swagger_ui_html": { + "occurrences": 6, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 6, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_redoc_html": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_swagger_ui_oauth2_redirect_html": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "StaticFiles": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/custom_request_and_route", + "method_count": 18, + "algorithm": "CRX", + "grammar": "root ::= (\"GzipRequest\" | \"HTTPException\" | \"Request\" | \"RequestValidationError\" | \"Response\" | \"_body\" | \"async\" | \"await\" | \"before\" | \"body\" | \"custom_route_handler\" | \"decode\" | \"decompress\" | \"def\" | \"detail\" | \"duration\" | \"errors\" | \"exc\" | \"except\" | \"get_route_handler\" | \"getlist\" | \"gzip\" | \"hasattr\" | \"headers\" | \"if\" | \"in\" | \"not\" | \"original_route_handler\" | \"print\" | \"raise\" | \"receive\" | \"request\" | \"response\" | \"return\" | \"scope\" | \"self\" | \"status_code\" | \"str\" | \"super\" | \"time\" | \"try\")+ \"sum\"?+ \"numbers\"?", + "mdl_score": 1000000000000, + "imports": [ + "import gzip", + "from collections.abc import Callable", + "from typing import Annotated", + "from fastapi import Body, FastAPI, Request, Response", + "from fastapi.routing import APIRoute", + "from fastapi import Body, FastAPI, HTTPException, Request, Response", + "from fastapi.exceptions import RequestValidationError", + "import time", + "from fastapi import APIRouter, FastAPI, Request, Response" + ], + "arg_patterns": { + "Body": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "super": { + "occurrences": 28, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 28, + "args": 0, + "types": [] + } + ] + }, + "original_route_handler": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "sum": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPException": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "ValidationErrorLoggingRoute": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 7, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "hasattr": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "GzipRequest": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "GzipRoute": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIRouter": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "str": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "print": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "TimedRoute": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/custom_response", + "method_count": 19, + "algorithm": "CRX", + "grammar": "root ::= \"for\"? \"def\"? \"i\"? \"in\"? \"range\"?+ (\"FileResponse\" | \"HTMLResponse\" | \"StreamingResponse\" | \"content\" | \"dumps\" | \"file_like\" | \"from\" | \"html_content\" | \"is\" | \"is not\" | \"iterfile\" | \"mode\" | \"not\" | \"open\" | \"option\" | \"orjson\" | \"return\" | \"some_file_path\" | \"yield\")+ (\"OPT_INDENT_2\" | \"ORJSONResponse\" | \"RedirectResponse\" | \"fake_video_streamer\" | \"generate_html_response\" | \"media_type\" | \"status_code\")?+ \"await\"? \"anyio\"? \"sleep\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.responses import UJSONResponse", + "from fastapi.responses import ORJSONResponse", + "from fastapi.responses import HTMLResponse", + "from fastapi.responses import PlainTextResponse", + "from fastapi.responses import RedirectResponse", + "import anyio", + "from fastapi.responses import StreamingResponse", + "from fastapi.responses import FileResponse", + "from typing import Any", + "import orjson", + "from fastapi import FastAPI, Response" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 45, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 42, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "StreamingResponse": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "call", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "iterfile": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "open": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "CustomORJSONResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTMLResponse": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "range": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "fake_video_streamer": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "RedirectResponse": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "ORJSONResponse": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "generate_html_response": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "FileResponse": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/dataclasses_", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"author_id\"? \"item\"? \"items\"?", + "mdl_score": 8, + "imports": [ + "from dataclasses import dataclass", + "from fastapi import FastAPI", + "from dataclasses import dataclass, field", + "from dataclasses import field # (1)", + "from pydantic.dataclasses import dataclass # (2)" + ], + "arg_patterns": { + "field": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/dependencies", + "method_count": 82, + "algorithm": "CRX", + "grammar": "root ::= (\"HTTPException\" | \"InternalError\" | \"OwnerError\" | \"close\" | \"commons\" | \"db\" | \"dep_a\" | \"dep_b\" | \"detail\" | \"except\" | \"fake_items_db\" | \"finally\" | \"fixed_content\" | \"if\" | \"in\" | \"item_id\" | \"items\" | \"limit\" | \"not\" | \"print\" | \"q\" | \"query\" | \"raise\" | \"response\" | \"return\" | \"self\" | \"session\" | \"skip\" | \"status_code\" | \"try\" | \"update\" | \"username\" | \"x_key\" | \"x_token\" | \"yield\")+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import Depends, FastAPI", + "from typing import Annotated, Any", + "from fastapi import Cookie, Depends, FastAPI", + "from fastapi import Depends, FastAPI, Header, HTTPException", + "from fastapi import Depends", + "from fastapi import Depends, FastAPI, HTTPException", + "import time", + "from fastapi.responses import StreamingResponse", + "from sqlmodel import Field, Session, SQLModel, create_engine" + ], + "arg_patterns": { + "Depends": { + "occurrences": 123, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 111, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "FixedContentQueryChecker": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "FastAPI": { + "occurrences": 81, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 75, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "print": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "HTTPException": { + "occurrences": 54, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 54, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Header": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + } + ] + }, + "InternalError": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "DBSession": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "MySuperContextManager": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "generate_dep_a": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "generate_dep_b": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "generate_dep_c": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "create_engine": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Session": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "User": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "generate_stream": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "StreamingResponse": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Field": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "OwnerError": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Cookie": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/dependency_testing", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"get\" | \"response\" | \"status_code\")?+ \"return\"? \"json\"?+ \"commons\"? \"q\"? \"skip\"? \"limit\"?", + "mdl_score": 25600216, + "imports": [ + "from typing import Annotated", + "from fastapi import Depends, FastAPI", + "from fastapi.testclient import TestClient" + ], + "arg_patterns": { + "Depends": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/events", + "method_count": 7, + "imports": [ + "from fastapi import FastAPI", + "from contextlib import asynccontextmanager" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "open": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/extra_models", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"UserInDB\" | \"fake_password_hasher\" | \"fake_save_user\" | \"hashed_password\" | \"model_dump\" | \"password\" | \"print\" | \"return\" | \"user_in\" | \"user_in_db\" | \"user_saved\")+ \"items\"? \"raw_password\"? \"item_id\"?", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel, EmailStr", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "Item": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 11, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 11, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BaseItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CarItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PlaneItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "print": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "UserBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserIn": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserOut": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserInDB": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "fake_save_user": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "fake_password_hasher": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "docs_src/generate_clients", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= \"return\" (\"route\" | \"tags\")?+ \"name\"?", + "mdl_score": 24, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel", + "from fastapi.routing import APIRoute" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseMessage": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "User": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/handling_errors", + "method_count": 13, + "imports": [ + "from fastapi import FastAPI, HTTPException", + "from fastapi import FastAPI, Request", + "from fastapi.responses import JSONResponse", + "from fastapi.exceptions import RequestValidationError", + "from fastapi.responses import PlainTextResponse", + "from starlette.exceptions import HTTPException as StarletteHTTPException", + "from fastapi.encoders import jsonable_encoder", + "from pydantic import BaseModel", + "from fastapi.exception_handlers import (" + ], + "arg_patterns": { + "UnicornException": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "JSONResponse": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "class": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPException": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "print": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "http_exception_handler": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "request_validation_exception_handler": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "repr": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Item": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "jsonable_encoder": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "PlainTextResponse": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "call", + "kwarg" + ] + } + ] + }, + "str": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "docs_src/header_param_models", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"headers\"", + "mdl_score": 6, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, Header", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "Header": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "CommonHeaders": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/header_params", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"return\" (\"strange_header\" | \"user_agent\" | \"x_token\")", + "mdl_score": 18, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, Header" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "Header": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/json_base64_bytes", + "method_count": 3, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "DataInput": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DataOutput": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DataInputOutput": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/metadata", + "method_count": 6, + "imports": [ + "from fastapi import FastAPI" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 7, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 7, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/path_operation_advanced_configuration", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"HTTPException\" | \"Item\" | \"ValidationError\" | \"YAMLError\" | \"await\" | \"body\" | \"data\" | \"detail\" | \"e\" | \"errors\" | \"except\" | \"include_url\" | \"item\" | \"len\" | \"magic_data_reader\" | \"model_validate\" | \"raise\" | \"raw_body\" | \"request\" | \"return\" | \"safe_load\" | \"status_code\" | \"try\" | \"yaml\")+ \"route\"? \"name\"?", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from fastapi.routing import APIRoute", + "from pydantic import BaseModel", + "from fastapi import FastAPI, Request", + "import yaml", + "from fastapi import FastAPI, HTTPException, Request", + "from pydantic import BaseModel, ValidationError" + ], + "arg_patterns": { + "len": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "magic_data_reader": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPException": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "set": { + "occurrences": 5, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 5, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/path_operation_configuration", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"item\"?", + "mdl_score": 12, + "imports": [ + "from fastapi import FastAPI, status", + "from pydantic import BaseModel", + "from fastapi import FastAPI", + "from enum import Enum" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 21, + "args": 0, + "types": [] + } + ] + }, + "Tags": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Item": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "set": { + "occurrences": 25, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 25, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/path_params", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"ModelName\" | \"alexnet\" | \"if\" | \"is\" | \"model_name\" | \"return\" | \"value\")+ (\"file_path\" | \"item_id\" | \"user_id\")?", + "mdl_score": 968890104371, + "imports": [ + "from fastapi import FastAPI", + "from enum import Enum" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "ModelName": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/path_params_numeric_validations", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= (\"if\" | \"item_id\" | \"q\" | \"results\" | \"return\" | \"size\" | \"update\")+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, Path, Query", + "from fastapi import FastAPI, Path" + ], + "arg_patterns": { + "Query": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 36, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 36, + "args": 0, + "types": [] + } + ] + }, + "Path": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/pydantic_v1_in_v2", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"item\"", + "mdl_score": 3, + "imports": [ + "from fastapi import FastAPI", + "from pydantic.v1 import BaseModel", + "from pydantic import BaseModel as BaseModelV2", + "from typing import Annotated", + "from fastapi.temp_pydantic_v1_params import Body" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "Body": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ItemV2": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/python_types", + "method_count": 13, + "imports": [ + "from typing import Annotated" + ], + "arg_patterns": { + "print": { + "occurrences": 32, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_full_name": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "str": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/query_param_models", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"filter_query\"", + "mdl_score": 4, + "imports": [ + "from typing import Annotated, Literal", + "from fastapi import FastAPI, Query", + "from pydantic import BaseModel, Field", + "from typing import Literal" + ], + "arg_patterns": { + "Query": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Field": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "FilterParams": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/query_params", + "method_count": 6, + "imports": [ + "from fastapi import FastAPI" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/query_params_str_validations", + "method_count": 31, + "algorithm": "CRX", + "grammar": "root ::= (\"ValueError\" | \"choice\" | \"data\" | \"else\" | \"get\" | \"hidden_query\" | \"id\" | \"if\" | \"item\" | \"items\" | \"list\" | \"not\" | \"q\" | \"query_items\" | \"raise\" | \"random\" | \"results\" | \"return\" | \"startswith\" | \"update\")+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from typing import Annotated", + "from fastapi import FastAPI, Query", + "import random", + "from pydantic import AfterValidator" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 90, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 90, + "args": 0, + "types": [] + } + ] + }, + "Query": { + "occurrences": 84, + "arg_count": { + "min": 0, + "max": 8, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 18, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 12, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "AfterValidator": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "list": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ValueError": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "docs_src/request_files", + "method_count": 24, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? \"not\"? (\"HTMLResponse\" | \"content\" | \"else\" | \"file\" | \"filename\" | \"for\" | \"len\" | \"return\")+ \"in\"? \"files\"?", + "mdl_score": 34480840128, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, File, UploadFile", + "from fastapi.responses import HTMLResponse" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 30, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 30, + "args": 0, + "types": [] + } + ] + }, + "len": { + "occurrences": 40, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 40, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "File": { + "occurrences": 42, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 27, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "HTMLResponse": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/request_form_models", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"data\"", + "mdl_score": 4, + "imports": [ + "from typing import Annotated", + "from fastapi import FastAPI, Form", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Form": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "FormData": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/response_model", + "method_count": 16, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? \"teleport\"? (\"RedirectResponse\" | \"return\" | \"url\")+ (\"item\" | \"user\")? \"items\"? (\"Item\" | \"name\" | \"price\")?+ \"JSONResponse\"?+ \"item_id\"? \"content\"?", + "mdl_score": 19090476, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel", + "from typing import Any", + "from pydantic import BaseModel, EmailStr", + "from fastapi import FastAPI, Response", + "from fastapi.responses import JSONResponse, RedirectResponse", + "from fastapi.responses import RedirectResponse" + ], + "arg_patterns": { + "JSONResponse": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 36, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 36, + "args": 0, + "types": [] + } + ] + }, + "RedirectResponse": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "BaseUser": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserIn": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Item": { + "occurrences": 11, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserOut": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/schema_extra_example", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"item\" | \"item_id\" | \"results\" | \"return\")+", + "mdl_score": 8192, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel", + "from pydantic import BaseModel, Field", + "from typing import Annotated", + "from fastapi import Body, FastAPI" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + } + ] + }, + "Item": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Body": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "class": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Field": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "docs_src/security", + "method_count": 70, + "algorithm": "CRX", + "grammar": "root ::= (\"ACCESS_TOKEN_EXPIRE_MINUTES\" | \"ALGORITHM\" | \"DUMMY_HASH\" | \"HTTPException\" | \"HTTP_401_UNAUTHORIZED\" | \"InvalidTokenError\" | \"SECRET_KEY\" | \"Token\" | \"TokenData\" | \"UserInDB\" | \"access_token\" | \"access_token_expires\" | \"algorithm\" | \"algorithms\" | \"authenticate_user\" | \"copy\" | \"create_access_token\" | \"credentials\" | \"credentials_exception\" | \"current_user\" | \"data\" | \"datetime\" | \"db\" | \"decode\" | \"detail\" | \"disabled\" | \"else\" | \"encode\" | \"encoded_jwt\" | \"except\" | \"expire\" | \"expires_delta\" | \"fake_db\" | \"fake_decode_token\" | \"fake_users_db\" | \"form_data\" | \"get\" | \"get_user\" | \"hash\" | \"hashed_password\" | \"headers\" | \"if\" | \"in\" | \"is\" | \"jwt\" | \"minutes\" | \"not\" | \"now\" | \"password\" | \"password_hash\" | \"payload\" | \"plain_password\" | \"raise\" | \"return\" | \"scopes\" | \"status\" | \"status_code\" | \"timedelta\" | \"timezone\" | \"to_encode\" | \"token\" | \"token_data\" | \"try\" | \"update\" | \"user\" | \"user_dict\" | \"username\" | \"utc\" | \"verify\" | \"verify_password\")+ \"token_type\"?", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import Depends, FastAPI", + "from fastapi.security import OAuth2PasswordBearer", + "from pydantic import BaseModel", + "from fastapi import Depends, FastAPI, HTTPException, status", + "from fastapi.security import OAuth2PasswordBearer, OAuth2PasswordRequestForm", + "from datetime import datetime, timedelta, timezone", + "import jwt", + "from jwt.exceptions import InvalidTokenError", + "from pwdlib import PasswordHash", + "from fastapi import Depends, FastAPI, HTTPException, Security, status", + "from fastapi.security import (", + "from pydantic import BaseModel, ValidationError", + "from fastapi.security import HTTPBasic, HTTPBasicCredentials", + "import secrets" + ], + "arg_patterns": { + "OAuth2PasswordBearer": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Token": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserInDB": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_user": { + "occurrences": 30, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 18, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "verify_password": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "Security": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "Depends": { + "occurrences": 114, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 96, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "TokenData": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPException": { + "occurrences": 72, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 36, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 36, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "authenticate_user": { + "occurrences": 12, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 12, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + } + ] + }, + "FastAPI": { + "occurrences": 42, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 42, + "args": 0, + "types": [] + } + ] + }, + "User": { + "occurrences": 14, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "timedelta": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "create_access_token": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "class": { + "occurrences": 22, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 22, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBasic": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "fake_hash_password": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "fake_decode_token": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/separate_openapi_schemas", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"return\" (\"Item\" | \"description\" | \"name\")?+ \"item\"?", + "mdl_score": 52494, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 14, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/server_sent_events", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"ServerSentEvent\" | \"comment\" | \"continue\" | \"data\" | \"else\" | \"enumerate\" | \"event\" | \"for\" | \"i\" | \"id\" | \"if\" | \"in\" | \"is\" | \"is not\" | \"item\" | \"items\" | \"last_event_id\" | \"log_line\" | \"logs\" | \"not\" | \"prompt\" | \"raw_data\" | \"split\" | \"start\" | \"str\" | \"text\" | \"word\" | \"words\" | \"yield\")+ \"retry\"?", + "mdl_score": 1000000000000, + "imports": [ + "from collections.abc import AsyncIterable, Iterable", + "from fastapi import FastAPI", + "from fastapi.sse import EventSourceResponse", + "from pydantic import BaseModel", + "from collections.abc import AsyncIterable", + "from fastapi.sse import EventSourceResponse, ServerSentEvent", + "from typing import Annotated", + "from fastapi import FastAPI, Header" + ], + "arg_patterns": { + "ServerSentEvent": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 4, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "Prompt": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Item": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 27, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "enumerate": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "str": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Header": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "docs_src/settings", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"return\" \"config\"? (\"admin_email\" | \"app_name\" | \"settings\")?+ \"Settings\"?+ \"items_per_user\"?", + "mdl_score": 2058, + "imports": [ + "from fastapi import FastAPI", + "from .config import settings", + "from functools import lru_cache", + "from typing import Annotated", + "from fastapi import Depends, FastAPI", + "from . import config" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "Depends": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/settings/app02_an_py310", + "method_count": 4, + "imports": [ + "from functools import lru_cache", + "from typing import Annotated", + "from fastapi import Depends, FastAPI", + "from .config import Settings", + "from fastapi.testclient import TestClient", + "from .main import app, get_settings" + ], + "arg_patterns": { + "Settings": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Depends": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/settings/app02_py310", + "method_count": 4, + "imports": [ + "from functools import lru_cache", + "from fastapi import Depends, FastAPI", + "from .config import Settings", + "from fastapi.testclient import TestClient", + "from .main import app, get_settings" + ], + "arg_patterns": { + "Depends": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Settings": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/sql_databases", + "method_count": 30, + "algorithm": "CRX", + "grammar": "root ::= \"create_db_and_tables\"?+ \"SQLModel\"? \"Session\"?+ \"metadata\"? \"create_all\"?+ \"engine\"? (\"HTTPException\" | \"Hero\" | \"add\" | \"all\" | \"commit\" | \"db_hero\" | \"delete\" | \"detail\" | \"exclude_unset\" | \"exec\" | \"get\" | \"hero\" | \"hero_data\" | \"hero_db\" | \"hero_id\" | \"heroes\" | \"if\" | \"limit\" | \"model_dump\" | \"model_validate\" | \"not\" | \"offset\" | \"raise\" | \"refresh\" | \"return\" | \"select\" | \"session\" | \"sqlmodel_update\" | \"status_code\" | \"yield\")?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from fastapi import Depends, FastAPI, HTTPException, Query", + "from sqlmodel import Field, Session, SQLModel, create_engine, select" + ], + "arg_patterns": { + "Field": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "HTTPException": { + "occurrences": 30, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 30, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Session": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Query": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Hero": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "create_db_and_tables": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Depends": { + "occurrences": 33, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "select": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "create_engine": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "class": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "HeroBase": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeroUpdate": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeroPublic": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeroCreate": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/stream_data", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= \"return\"? \"read_image\"?+ \"BytesIO\"?+ (\"chunk\" | \"for\" | \"from\" | \"image_file\" | \"in\" | \"line\" | \"message\" | \"splitlines\" | \"yield\")?+ \"binary_image\"? \"encode\"?+", + "mdl_score": 2761427106, + "imports": [ + "from collections.abc import AsyncIterable, Iterable", + "from fastapi import FastAPI", + "from fastapi.responses import StreamingResponse", + "import base64", + "from io import BytesIO" + ], + "arg_patterns": { + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "read_image": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "BytesIO": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PNGStreamingResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/stream_json_lines", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"for\" (\"in\" | \"item\" | \"items\" | \"yield\")+", + "mdl_score": 4096, + "imports": [ + "from collections.abc import AsyncIterable, Iterable", + "from fastapi import FastAPI", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "Item": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "docs_src/websockets_", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= \"for\"? (\"WS_1008_POLICY_VIOLATION\" | \"WebSocketDisconnect\" | \"WebSocketException\" | \"accept\" | \"active_connections\" | \"and\" | \"append\" | \"await\" | \"broadcast\" | \"client_id\" | \"code\" | \"connect\" | \"connection\" | \"cookie_or_token\" | \"data\" | \"disconnect\" | \"except\" | \"if\" | \"in\" | \"is\" | \"is not\" | \"manager\" | \"not\" | \"or\" | \"q\" | \"raise\" | \"receive_text\" | \"remove\" | \"return\" | \"self\" | \"send_personal_message\" | \"send_text\" | \"session\" | \"status\" | \"token\" | \"try\" | \"websocket\" | \"while\")+ \"list\"?+ \"HTMLResponse\"?+ (\"item_id\" | \"message\")? \"WebSocket\"? \"html\"?", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI, WebSocket", + "from fastapi.responses import HTMLResponse", + "from typing import Annotated", + "from fastapi import (", + "from fastapi import FastAPI, WebSocket, WebSocketDisconnect" + ], + "arg_patterns": { + "HTMLResponse": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "WebSocketException": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Depends": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Query": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Cookie": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ConnectionManager": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "fastapi", + "method_count": 239, + "algorithm": "CRX", + "grammar": "root ::= (\"AsyncExitStack\" | \"Match\" | \"NONE\" | \"_IncludedRouter\" | \"__init__\" | \"alias\" | \"alias_priority\" | \"allow_inf_nan\" | \"and\" | \"app\" | \"async\" | \"await\" | \"callbacks\" | \"child_scope\" | \"decimal_places\" | \"def\" | \"default\" | \"default_factory\" | \"dependant\" | \"dependencies\" | \"dependency_overrides_provider\" | \"deprecated\" | \"description\" | \"dict\" | \"discriminator\" | \"else\" | \"endpoint\" | \"errors\" | \"example\" | \"examples\" | \"except\" | \"extra\" | \"for\" | \"func\" | \"ge\" | \"generate_unique_id_function\" | \"get\" | \"gt\" | \"if\" | \"in\" | \"include_in_schema\" | \"is\" | \"is not\" | \"isinstance\" | \"json_schema_extra\" | \"le\" | \"list\" | \"lt\" | \"match\" | \"max_digits\" | \"max_length\" | \"methods\" | \"min_length\" | \"multiple_of\" | \"name\" | \"not\" | \"openapi_examples\" | \"openapi_extra\" | \"operation_id\" | \"or\" | \"original_route\" | \"path\" | \"pattern\" | \"prefix\" | \"raise\" | \"receive\" | \"regex\" | \"response_class\" | \"response_description\" | \"response_model\" | \"response_model_by_alias\" | \"response_model_exclude\" | \"response_model_exclude_defaults\" | \"response_model_exclude_none\" | \"response_model_exclude_unset\" | \"response_model_include\" | \"responses\" | \"return\" | \"route\" | \"router\" | \"routes\" | \"rstrip\" | \"scope\" | \"self\" | \"send\" | \"serialization_alias\" | \"status_code\" | \"str\" | \"strict\" | \"summary\" | \"super\" | \"tags\" | \"title\" | \"try\" | \"validation_alias\" | \"value\" | \"yield\")+", + "mdl_score": 1000000000000, + "imports": [ + "import os", + "from collections.abc import Awaitable, Callable, Coroutine, Sequence", + "from enum import Enum", + "from typing import Annotated, Any, Literal, TypeVar", + "from annotated_doc import Doc", + "from fastapi import routing", + "from fastapi.datastructures import Default, DefaultPlaceholder", + "from fastapi.exception_handlers import (", + "from fastapi.exceptions import RequestValidationError, WebSocketRequestValidationError", + "from fastapi.logger import logger", + "from fastapi.middleware.asyncexitstack import AsyncExitStackMiddleware", + "from fastapi.openapi.docs import (", + "from fastapi.openapi.utils import get_openapi", + "from fastapi.params import Depends", + "from fastapi.types import DecoratedCallable, IncEx", + "from fastapi.utils import generate_unique_id", + "from starlette.applications import Starlette", + "from starlette.datastructures import State", + "from starlette.exceptions import HTTPException", + "from starlette.middleware import Middleware", + "from starlette.middleware.base import BaseHTTPMiddleware", + "from starlette.middleware.errors import ServerErrorMiddleware", + "from starlette.middleware.exceptions import ExceptionMiddleware", + "from starlette.requests import Request", + "from starlette.responses import HTMLResponse, JSONResponse, Response", + "from starlette.routing import BaseRoute", + "from starlette.types import ASGIApp, ExceptionHandler, Lifespan, Receive, Scope, Send", + "from typing_extensions import deprecated", + "from fastapi import FastAPI", + "from Starlette and supported for compatibility.", + "from collections.abc import Callable", + "from typing import Annotated, Any", + "from starlette.background import BackgroundTasks as StarletteBackgroundTasks", + "from typing_extensions import ParamSpec", + "from fastapi import BackgroundTasks, FastAPI", + "from fastapi_cli.cli import main as cli_main", + "from collections.abc import AsyncGenerator", + "from contextlib import AbstractContextManager", + "from contextlib import asynccontextmanager as asynccontextmanager", + "from typing import TypeVar", + "import anyio.to_thread", + "from anyio import CapacityLimiter", + "from starlette.concurrency import iterate_in_threadpool as iterate_in_threadpool # noqa", + "from starlette.concurrency import run_in_threadpool as run_in_threadpool # noqa", + "from starlette.concurrency import ( # noqa", + "from collections.abc import Callable, Mapping", + "from typing import (", + "from pydantic import GetJsonSchemaHandler", + "from starlette.datastructures import URL as URL # noqa: F401", + "from starlette.datastructures import Address as Address # noqa: F401", + "from starlette.datastructures import FormData as FormData # noqa: F401", + "from starlette.datastructures import Headers as Headers # noqa: F401", + "from starlette.datastructures import QueryParams as QueryParams # noqa: F401", + "from starlette.datastructures import State as State # noqa: F401", + "from starlette.datastructures import UploadFile as StarletteUploadFile", + "from typing import Annotated", + "from fastapi import FastAPI, File, UploadFile", + "from ._compat.v2 import with_info_plain_validator_function", + "import dataclasses", + "import datetime", + "from collections import defaultdict, deque", + "from decimal import Decimal", + "from ipaddress import (", + "from pathlib import Path, PurePath", + "from re import Pattern", + "from types import GeneratorType", + "from uuid import UUID", + "from fastapi.exceptions import PydanticV1NotSupportedError", + "from fastapi.types import IncEx", + "from pydantic import BaseModel", + "from pydantic.networks import AnyUrl, NameEmail", + "from pydantic.types import SecretBytes, SecretStr", + "from pydantic_core import PydanticUndefinedType", + "from ._compat import (", + "from pydantic.color import Color # ty: ignore[deprecated]", + "from pydantic_extra_types.color import Color as PyExtraColor", + "from fastapi.encoders import jsonable_encoder", + "from fastapi.utils import is_body_allowed_for_status_code", + "from fastapi.websockets import WebSocket", + "from starlette.responses import JSONResponse, Response", + "from starlette.status import WS_1008_POLICY_VIOLATION", + "from collections.abc import Mapping, Sequence", + "from typing import Annotated, Any, TypedDict", + "from pydantic import BaseModel, create_model", + "from starlette.exceptions import HTTPException as StarletteHTTPException", + "from starlette.exceptions import WebSocketException as StarletteWebSocketException", + "from fastapi import FastAPI, HTTPException", + "from fastapi import (", + "from contextlib import AsyncExitStack", + "from starlette.types import ASGIApp, Receive, Scope, Send", + "from collections.abc import Callable, Sequence", + "from typing import Annotated, Any, Literal", + "from fastapi import params", + "from fastapi._compat import Undefined", + "from fastapi.datastructures import _Unset", + "from fastapi.openapi.models import Example", + "from pydantic import AliasChoices, AliasPath", + "import warnings", + "from dataclasses import dataclass", + "from fastapi.exceptions import FastAPIDeprecationWarning", + "from pydantic.fields import FieldInfo", + "from .datastructures import _Unset", + "import importlib", + "from typing import Any, Protocol, cast", + "from fastapi.sse import EventSourceResponse as EventSourceResponse # noqa", + "from starlette.responses import FileResponse as FileResponse # noqa", + "from starlette.responses import HTMLResponse as HTMLResponse # noqa", + "from starlette.responses import JSONResponse as JSONResponse # noqa", + "from starlette.responses import PlainTextResponse as PlainTextResponse # noqa", + "from starlette.responses import RedirectResponse as RedirectResponse # noqa", + "from starlette.responses import Response as Response # noqa", + "from starlette.responses import StreamingResponse as StreamingResponse # noqa", + "import contextlib", + "import copy", + "import email.message", + "import errno", + "import functools", + "import inspect", + "import json", + "import stat", + "import types", + "from collections.abc import (", + "from contextlib import (", + "from contextvars import ContextVar", + "from dataclasses import dataclass, field", + "from enum import Enum, IntEnum", + "import anyio", + "from anyio.abc import ObjectReceiveStream", + "from fastapi._compat import (", + "from fastapi.dependencies.models import Dependant", + "from fastapi.dependencies.utils import (", + "from fastapi.exceptions import (", + "from fastapi.sse import (", + "from fastapi.utils import (", + "from starlette import routing", + "from starlette._exception_handler import wrap_app_handling_exceptions", + "from starlette._utils import get_route_path, is_async_callable", + "from starlette.concurrency import iterate_in_threadpool, run_in_threadpool", + "from starlette.datastructures import URL, FormData, URLPath", + "from starlette.responses import (", + "from starlette.routing import (", + "from starlette.routing import Mount as Mount # noqa", + "from starlette.staticfiles import StaticFiles", + "from starlette.types import AppType, ASGIApp, Lifespan, Receive, Scope, Send", + "from starlette.websockets import WebSocket", + "from pydantic import AfterValidator, BaseModel, Field, model_validator", + "from starlette.responses import StreamingResponse", + "import re", + "import fastapi", + "from fastapi.datastructures import DefaultPlaceholder, DefaultType", + "from fastapi.exceptions import FastAPIDeprecationWarning, PydanticV1NotSupportedError", + "from ._compat import v2", + "from .routing import APIRoute" + ], + "arg_patterns": { + "CapacityLimiter": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "type": { + "occurrences": 35, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "TypeVar": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "bool": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "run_in_threadpool": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 4, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "other", + "var", + "other", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "JSONResponse": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "other", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "jsonable_encoder": { + "occurrences": 33, + "arg_count": { + "min": 1, + "max": 9, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 9, + "types": [ + "var", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 6, + "args": 6, + "types": [ + "var", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "var", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "getattr": { + "occurrences": 48, + "arg_count": { + "min": 2, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 28, + "args": 3, + "types": [ + "other", + "lit", + "lit" + ] + }, + { + "count": 16, + "args": 3, + "types": [ + "var", + "lit", + "lit" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "Response": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "other" + ] + } + ] + }, + "is_body_allowed_for_status_code": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "print": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RuntimeError": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cli_main": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "AfterValidator": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ValueError": { + "occurrences": 20, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "EventSourceResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Doc": { + "occurrences": 2121, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2121, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Field": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "ServerSentEvent": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_check_single_line": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "model_validator": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "class": { + "occurrences": 40, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 35, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 1, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "AsyncExitStack": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 21, + "args": 0, + "types": [] + } + ] + }, + "encoder": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "set": { + "occurrences": 50, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 20, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 20, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "isinstance": { + "occurrences": 288, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 224, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 32, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 16, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "subscript", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "float": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "encoder_instance": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_pydantic_v1_model_instance": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "vars": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "int": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "dict": { + "occurrences": 35, + "arg_count": { + "min": 1, + "max": 17, + "common": 1 + }, + "patterns": [ + { + "count": 20, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 10, + "args": 17, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "other" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "PydanticV1NotSupportedError": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "str": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "defaultdict": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "generate_encoders_by_class_tuples": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "deprecated": { + "occurrences": 136, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 83, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 45, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 8, + "args": 3, + "types": [ + "other", + "kwarg", + "kwarg" + ] + } + ] + }, + "cast": { + "occurrences": 27, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 18, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "var", + "call" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "expr", + "var" + ] + } + ] + }, + "ORJSONResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_UjsonModule": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_OrjsonModule": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UJSONResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Default": { + "occurrences": 267, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 177, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 90, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_swagger_ui_html": { + "occurrences": 3, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "list": { + "occurrences": 45, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 25, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_openapi": { + "occurrences": 3, + "arg_count": { + "min": 14, + "max": 14, + "common": 14 + }, + "patterns": [ + { + "count": 3, + "args": 14, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "cls": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 12, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 12, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "reversed": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Middleware": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "super": { + "occurrences": 104, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 104, + "args": 0, + "types": [] + } + ] + }, + "get_swagger_ui_oauth2_redirect_html": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "FastAPI": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "State": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "get_redoc_html": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "BackgroundTasks": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ParamSpec": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "UploadFile": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "with_info_plain_validator_function": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "DefaultPlaceholder": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Header": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ParamTypes": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Query": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Cookie": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Body": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "File": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "dataclass": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Path": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Param": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Security": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Form": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FieldInfo": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "annotation_is_pydantic_v1": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "deep_dict_update": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "subscript", + "var" + ] + } + ] + }, + "cmgr": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_frontend_scope_specificity": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_serialize_data": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_value_or_default": { + "occurrences": 33, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 15, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 9, + "args": 3, + "types": [ + "other", + "other", + "other" + ] + }, + { + "count": 9, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "_build_dependant_with_parameterless_dependencies": { + "occurrences": 12, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 12, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_route_path": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_AsyncLiftContextManager": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "Request": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "solve_dependencies": { + "occurrences": 9, + "arg_count": { + "min": 5, + "max": 6, + "common": 5 + }, + "patterns": [ + { + "count": 6, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 6, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "RedirectResponse": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "callable": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RequestValidationError": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "other", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIRoute": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_get_fastapi_scope": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "field": { + "occurrences": 57, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 54, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "_IncludedRouter": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "NoMatchFound": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "current_generate_unique_id": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIWebSocketRoute": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "expr", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 5, + "types": [ + "call", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "FastAPIError": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_get_scope_effective_route_context": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "URL": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "func": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_async_callable": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "URLPath": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "RouteContext": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_FrontendStaticFiles": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_FrontendRoute": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "var", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_get_resolved_absolute_path": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "request_response": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "compile_path": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "wrap_app_handling_exceptions": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "_restore_fastapi_scope_key": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "create_model_field": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "response": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "ResponseValidationError": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_frontend_path_specificity": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_normalize_frontend_path": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_FrontendRouteGroup": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "id": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_wrap_gen_lifespan_context": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_sync_stream_jsonl": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "EndpointContext": { + "occurrences": 16, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "_update_scope": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "lenient_issubclass": { + "occurrences": 15, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 15, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "_iter_accept_media_types": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "_serialize_item": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PlainTextResponse": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + } + ] + }, + "HTTPException": { + "occurrences": 28, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "nested_context": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "f": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "asynccontextmanager": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "original_context": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "handler": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "_RouterIncludeContext": { + "occurrences": 3, + "arg_count": { + "min": 12, + "max": 12, + "common": 12 + }, + "patterns": [ + { + "count": 3, + "args": 12, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "AssertionError": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "_async_stream_jsonl": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "_APIRouteLike": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_join_frontend_paths": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "_EffectiveRouteContext": { + "occurrences": 15, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 15, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "_RouteWithPath": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "WebSocketRequestValidationError": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_populate_api_route_state": { + "occurrences": 6, + "arg_count": { + "min": 28, + "max": 28, + "common": 28 + }, + "patterns": [ + { + "count": 3, + "args": 28, + "types": [ + "call", + "call", + "other", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 28, + "types": [ + "call", + "var", + "var", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_body_field": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "_iter_routes_with_context": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "len": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_extract_endpoint_context": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "object": { + "occurrences": 5, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 5, + "args": 0, + "types": [] + } + ] + }, + "_serialize_sse_item": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "serialize_response": { + "occurrences": 3, + "arg_count": { + "min": 11, + "max": 11, + "common": 11 + }, + "patterns": [ + { + "count": 3, + "args": 11, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "hasattr": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "_sse_producer_cm": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "app": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "_should_embed_body_fields": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "route_class": { + "occurrences": 3, + "arg_count": { + "min": 27, + "max": 27, + "common": 27 + }, + "patterns": [ + { + "count": 3, + "args": 27, + "types": [ + "expr", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "APIRouter": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_name": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_flat_dependant": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ContextVar": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "_build_response_args": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "iterate_in_threadpool": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_parameterless_sub_dependant": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "serializer": { + "occurrences": 3, + "arg_count": { + "min": 7, + "max": 7, + "common": 7 + }, + "patterns": [ + { + "count": 3, + "args": 7, + "types": [ + "var", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_stream_item_type": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_dependant": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "StreamingResponse": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + } + ] + }, + "_get_scope_included_router": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "run_endpoint_function": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "format_sse_event": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 5, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_typed_return_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_sse_with_checkpoints": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "actual_response_class": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "other" + ] + } + ] + }, + "get_websocket_app": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "websocket_session": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "WebSocket": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + } + ] + }, + "_is_frontend_navigation_request": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_request_handler": { + "occurrences": 3, + "arg_count": { + "min": 16, + "max": 16, + "common": 16 + }, + "patterns": [ + { + "count": 3, + "args": 16, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "_DefaultLifespan": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_merge_lifespan_context": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "_async_stream_raw": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPIDeprecationWarning": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "create_model": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "ValidationException": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DependencyScopeError": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "WebSocketException": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "fastapi/_compat", + "method_count": 45, + "imports": [ + "import types", + "import typing", + "import warnings", + "from collections import deque", + "from collections.abc import Mapping, Sequence", + "from dataclasses import is_dataclass", + "from typing import (", + "from fastapi.types import UnionType", + "from pydantic import BaseModel", + "from pydantic.version import VERSION as PYDANTIC_VERSION", + "from starlette.datastructures import UploadFile", + "from pydantic import v1", + "import re", + "from collections.abc import Sequence", + "from copy import copy", + "from dataclasses import dataclass, is_dataclass", + "from enum import Enum", + "from functools import lru_cache", + "from fastapi._compat import lenient_issubclass, shared", + "from fastapi.openapi.constants import REF_TEMPLATE", + "from fastapi.types import IncEx, ModelNameMap, UnionType", + "from pydantic import BaseModel, ConfigDict, Field, TypeAdapter, create_model", + "from pydantic import PydanticSchemaGenerationError as PydanticSchemaGenerationError", + "from pydantic import PydanticUndefinedAnnotation as PydanticUndefinedAnnotation", + "from pydantic import ValidationError as ValidationError", + "from pydantic._internal import _typing_extra as _pydantic_typing_extra", + "from pydantic._internal._schema_generation_shared import ( # type: ignore[attr-defined]", + "from pydantic.fields import FieldInfo as FieldInfo", + "from pydantic.json_schema import GenerateJsonSchema as _GenerateJsonSchema", + "from pydantic.json_schema import JsonSchemaValue as JsonSchemaValue", + "from pydantic_core import CoreSchema as CoreSchema", + "from pydantic_core import PydanticUndefined", + "from pydantic_core import Url as Url", + "from pydantic_core.core_schema import (", + "from pydantic.warnings import UnsupportedFieldAttributeWarning" + ], + "arg_patterns": { + "FieldInfo": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "lenient_issubclass": { + "occurrences": 39, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 15, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "set": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "_regenerate_error_with_loc": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "len": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_has_computed_fields": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_flat_models_from_fields": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "cast": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "subscript", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "subscript" + ] + } + ] + }, + "get_origin": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ModelField": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_model_fields": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "GenerateJsonSchema": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_args": { + "occurrences": 45, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 42, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "type": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "create_model": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "list": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_flat_models_from_field": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "copy": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "getattr": { + "occurrences": 8, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "lit", + "lit" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "issubclass": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "get_flat_models_from_model": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "normalize_name": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "asdict": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_flat_models_from_annotation": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "isinstance": { + "occurrences": 28, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 16, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 8, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "Field": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "is_dataclass": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TypeAdapter": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "subscript", + "other", + "kwarg" + ] + } + ] + }, + "try_eval_type": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "id": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_annotation_is_complex": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "field_annotation_is_sequence": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_annotation_is_sequence": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "int": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "all": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "field_annotation_is_complex": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "hasattr": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "field_annotation_is_scalar": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_bytes_sequence_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_pydantic_v1_model_class": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "any": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "is_uploadfile_or_nonable_uploadfile_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "annotation_is_pydantic_v1": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TypeVar": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "is_bytes_or_nonable_bytes_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "tuple": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 2, + "types": [ + "call", + "other" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "is_uploadfile_sequence_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "field_annotation_is_scalar_sequence": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "fastapi/dependencies", + "method_count": 38, + "imports": [ + "import inspect", + "import sys", + "from collections.abc import Callable", + "from dataclasses import dataclass, field", + "from functools import cached_property, partial", + "from typing import Any, Literal", + "from fastapi._compat import ModelField", + "from fastapi.security.base import SecurityBase", + "from fastapi.types import DependencyCacheKey", + "from inspect import iscoroutinefunction", + "from asyncio import iscoroutinefunction", + "import dataclasses", + "from collections.abc import (", + "from contextlib import AsyncExitStack, contextmanager", + "from copy import copy, deepcopy", + "from dataclasses import dataclass", + "from typing import (", + "from fastapi import params", + "from fastapi._compat import (", + "from fastapi.background import BackgroundTasks", + "from fastapi.concurrency import (", + "from fastapi.dependencies.models import Dependant", + "from fastapi.exceptions import DependencyScopeError", + "from fastapi.logger import logger", + "from fastapi.security.oauth2 import SecurityScopes", + "from fastapi.utils import create_model_field, get_path_param_names", + "from pydantic import BaseModel, Json", + "from pydantic.fields import FieldInfo", + "from starlette.background import BackgroundTasks as StarletteBackgroundTasks", + "from starlette.concurrency import run_in_threadpool", + "from starlette.datastructures import (", + "from starlette.requests import HTTPConnection, Request", + "from starlette.responses import Response", + "from starlette.websockets import WebSocket", + "from typing_inspection.typing_objects import is_typealiastype", + "from python_multipart import __version__", + "from multipart import ( # type: ignore[no-redef,import-untyped]", + "from multipart.multipart import ( # type: ignore[import-untyped]" + ], + "arg_patterns": { + "get_cached_model_fields": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "create_body_model": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "_get_flat_fields_from_params": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isinstance": { + "occurrences": 164, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 76, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 60, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 28, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "serialize_sequence_value": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "get_validation_alias": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ParamDetails": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "is_uploadfile_or_nonable_uploadfile_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "len": { + "occurrences": 32, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 28, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "getattr": { + "occurrences": 68, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 24, + "args": 3, + "types": [ + "call", + "lit", + "lit" + ] + }, + { + "count": 16, + "args": 3, + "types": [ + "var", + "lit", + "lit" + ] + }, + { + "count": 12, + "args": 3, + "types": [ + "var", + "lit", + "other" + ] + }, + { + "count": 12, + "args": 3, + "types": [ + "other", + "lit", + "lit" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "other", + "lit", + "var" + ] + } + ] + }, + "ForwardRef": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ensure_multipart_is_installed": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "value_is_sequence": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_missing_field_error": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_flat_dependant": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 4, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "var", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "lenient_issubclass": { + "occurrences": 39, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 21, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 15, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "get_args": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SolvedDependency": { + "occurrences": 3, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "copy_field_info": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "SecurityScopes": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "create_model_field": { + "occurrences": 6, + "arg_count": { + "min": 4, + "max": 5, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "request_params_to_args": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "RuntimeError": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_bytes_sequence_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Response": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "_get_signature": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_validate_value_with_model_field": { + "occurrences": 12, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 12, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "request_body_to_args": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "other", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_dependant": { + "occurrences": 9, + "arg_count": { + "min": 4, + "max": 7, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 7, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "is_union_of_base_models": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Dependant": { + "occurrences": 6, + "arg_count": { + "min": 7, + "max": 18, + "common": 18 + }, + "patterns": [ + { + "count": 3, + "args": 7, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 18, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "is_typealiastype": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "type": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "any": { + "occurrences": 16, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "call", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "expr", + "other" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "lit", + "other", + "other" + ] + } + ] + }, + "list": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "run_in_threadpool": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "field_annotation_is_sequence": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_get_multidict_value": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "kwarg" + ] + } + ] + }, + "solve_dependencies": { + "occurrences": 3, + "arg_count": { + "min": 9, + "max": 9, + "common": 9 + }, + "patterns": [ + { + "count": 3, + "args": 9, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "_extract_form_body": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "is_uploadfile_sequence_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyFieldInfo": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_typed_signature": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "set": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 0, + "types": [] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "_is_json_field": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "callable": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "is_scalar_field": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "contextmanager": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "contextmanager_in_threadpool": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "copy": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_typed_annotation": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "add_non_field_param_to_dependency": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "field_annotation_is_scalar_sequence": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_path_param_names": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "call": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "add_param_to_fields": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "cast": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "subscript", + "other" + ] + } + ] + }, + "BackgroundTasks": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "is_bytes_or_nonable_bytes_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "deepcopy": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "asynccontextmanager": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_solve_generator": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_origin": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "field_annotation_is_scalar": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "analyze_param": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "evaluate_forwardref": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "DependencyScopeError": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_impartial": { + "occurrences": 42, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 21, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "field": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "_unwrapped_call": { + "occurrences": 54, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 36, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "iscoroutinefunction": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "tuple": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "sorted": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + } + } + }, + { + "label": "fastapi/openapi", + "method_count": 19, + "imports": [ + "import json", + "from typing import Annotated, Any", + "from annotated_doc import Doc", + "from fastapi.encoders import jsonable_encoder", + "from starlette.responses import HTMLResponse", + "from collections.abc import Callable, Iterable, Mapping", + "from enum import Enum", + "from typing import Annotated, Any, Literal, Optional, Union", + "from fastapi._compat import with_info_plain_validator_function", + "from fastapi.logger import logger", + "from pydantic import (", + "from typing_extensions import TypedDict", + "from typing_extensions import deprecated as typing_deprecated", + "import email_validator", + "from pydantic import EmailStr", + "import copy", + "import http.client", + "import inspect", + "import warnings", + "from collections.abc import Sequence", + "from typing import Any, Literal, cast", + "from fastapi import routing", + "from fastapi._compat import (", + "from fastapi.datastructures import DefaultPlaceholder, _Unset", + "from fastapi.dependencies.models import Dependant", + "from fastapi.dependencies.utils import (", + "from fastapi.exceptions import FastAPIDeprecationWarning", + "from fastapi.openapi.constants import METHODS_WITH_BODY, REF_PREFIX", + "from fastapi.openapi.models import OpenAPI", + "from fastapi.params import Body, ParamTypes", + "from fastapi.responses import Response", + "from fastapi.sse import _SSE_EVENT_SCHEMA", + "from fastapi.types import ModelNameMap", + "from fastapi.utils import (", + "from pydantic import BaseModel", + "from starlette.responses import JSONResponse", + "from starlette.routing import BaseRoute" + ], + "arg_patterns": { + "get_fields_from_routes": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_schema_from_model_field": { + "occurrences": 18, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 18, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "isinstance": { + "occurrences": 28, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 8, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "list": { + "occurrences": 20, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "get_flat_dependant": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "len": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_get_openapi_operation_parameters": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "_get_api_route_for_openapi": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_get_flat_fields_from_params": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getattr": { + "occurrences": 32, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 16, + "args": 3, + "types": [ + "var", + "lit", + "lit" + ] + }, + { + "count": 8, + "args": 3, + "types": [ + "other", + "lit", + "lit" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "other", + "lit", + "var" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "other", + "lit", + "other" + ] + } + ] + }, + "str": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 20, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_openapi_path": { + "occurrences": 9, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 9, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "lenient_issubclass": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "cast": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "jsonable_encoder": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "call", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "other", + "kwarg", + "kwarg" + ] + } + ] + }, + "int": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_flat_models_from_fields": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "get_definitions": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_openapi_operation_request_body": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_flat_params": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "set": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "sorted": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_body_allowed_for_status_code": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "get_validation_alias": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "deep_dict_update": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "generate_operation_summary": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "get_openapi_security_definitions": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "OpenAPI": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_model_name_map": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "generate_operation_id_for_path": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_openapi_operation_metadata": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "any": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "expr", + "other" + ] + } + ] + }, + "Doc": { + "occurrences": 42, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 42, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "_html_safe_json": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTMLResponse": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Example": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "Field": { + "occurrences": 99, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 84, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 15, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "ParameterInType": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBearer": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OpenIdConnect": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "with_info_plain_validator_function": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Server": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RequestBody": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Schema": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuth2": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Tag": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MediaType": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIKey": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Components": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Info": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuthFlows": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Contact": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Reference": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Parameter": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "XML": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Header": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ParameterBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SecurityBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuthFlowAuthorizationCode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "EmailStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ServerVariable": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Response": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIKeyIn": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BaseModelWithConfig": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Operation": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuthFlowPassword": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Encoding": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuthFlowClientCredentials": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PathItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuthFlow": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ExternalDocumentation": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Link": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SecuritySchemeType": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuthFlowImplicit": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "typing_deprecated": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "License": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Discriminator": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 41, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 40, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 1, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "fastapi/security", + "method_count": 34, + "algorithm": "CRX", + "grammar": "root ::= (\"APIKey\" | \"APIKeyIn\" | \"Annotated\" | \"Any\" | \"Doc\" | \"Error\" | \"HTTPAuthorizationCredentials\" | \"HTTPBaseModel\" | \"HTTPBasicCredentials\" | \"HTTPBearerModel\" | \"HTTPException\" | \"HTTP_401_UNAUTHORIZED\" | \"OAuth2Model\" | \"OAuthFlowsModel\" | \"OpenIdConnectModel\" | \"UnicodeDecodeError\" | \"ValueError\" | \"_\" | \"__class__\" | \"__init__\" | \"__name__\" | \"and\" | \"api_key\" | \"authorization\" | \"authorizationCode\" | \"authorizationUrl\" | \"authorization_header_value\" | \"auto_error\" | \"b64decode\" | \"bearerFormat\" | \"binascii\" | \"cast\" | \"check_api_key\" | \"client_id\" | \"cookie\" | \"cookies\" | \"credentials\" | \"data\" | \"decode\" | \"description\" | \"detail\" | \"e\" | \"else\" | \"except\" | \"flows\" | \"from\" | \"get\" | \"get_authorization_scheme_param\" | \"grant_type\" | \"header\" | \"headers\" | \"if\" | \"join\" | \"list\" | \"location\" | \"lower\" | \"make_not_authenticated_error\" | \"model\" | \"name\" | \"not\" | \"openIdConnectUrl\" | \"or\" | \"param\" | \"partition\" | \"password\" | \"query\" | \"query_params\" | \"raise\" | \"realm\" | \"refreshUrl\" | \"request\" | \"return\" | \"scheme\" | \"scheme_name\" | \"scope\" | \"scope_str\" | \"scopes\" | \"self\" | \"separator\" | \"split\" | \"status_code\" | \"str\" | \"super\" | \"tokenUrl\" | \"try\" | \"username\")+ (\"client_secret\" | \"make_authenticate_headers\" | \"strip\" | \"title\")?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "from annotated_doc import Doc", + "from fastapi.openapi.models import APIKey, APIKeyIn", + "from fastapi.security.base import SecurityBase", + "from starlette.exceptions import HTTPException", + "from starlette.requests import Request", + "from starlette.status import HTTP_401_UNAUTHORIZED", + "include a WWW-Authenticate header.", + "from fastapi import Depends, FastAPI", + "from fastapi.security import APIKeyQuery", + "from fastapi.security import APIKeyHeader", + "import binascii", + "from base64 import b64decode", + "from fastapi.exceptions import HTTPException", + "from fastapi.openapi.models import HTTPBase as HTTPBaseModel", + "from fastapi.openapi.models import HTTPBearer as HTTPBearerModel", + "from fastapi.security.utils import get_authorization_scheme_param", + "from pydantic import BaseModel", + "from fastapi.security import HTTPBasic, HTTPBasicCredentials", + "from typing import Annotated, Any, cast", + "from fastapi.openapi.models import OAuth2 as OAuth2Model", + "from fastapi.openapi.models import OAuthFlows as OAuthFlowsModel", + "from fastapi.param_functions import Form", + "from fastapi.security import OAuth2PasswordRequestForm", + "from fastapi.openapi.models import OpenIdConnect as OpenIdConnectModel" + ], + "arg_patterns": { + "Doc": { + "occurrences": 186, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 186, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "HTTPException": { + "occurrences": 12, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 12, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "OpenIdConnectModel": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "OpenIdConnect": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "super": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + } + ] + }, + "APIKeyBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIKeyQuery": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIKeyCookie": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIKey": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "other", + "other", + "kwarg", + "kwarg" + ] + } + ] + }, + "APIKeyHeader": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Form": { + "occurrences": 36, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "get_authorization_scheme_param": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cast": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "OAuthFlowsModel": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "OAuth2Model": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "OAuth2": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuth2AuthorizationCodeBearer": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuth2PasswordRequestFormStrict": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuth2PasswordBearer": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBaseModel": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "HTTPBasic": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPAuthorizationCredentials": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBearerModel": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "b64decode": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPDigest": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBasicCredentials": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBearer": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "scripts", + "method_count": 132, + "imports": [ + "import re", + "import sys", + "from datetime import date", + "import logging", + "import secrets", + "import subprocess", + "from collections import Counter", + "from datetime import datetime", + "from pathlib import Path", + "from typing import Any", + "import httpx", + "import yaml", + "from github import Github", + "from pydantic import BaseModel, SecretStr", + "from pydantic_settings import BaseSettings", + "from typing import Literal", + "from github import Auth, Github", + "from typing import TypedDict", + "import json", + "import os", + "import shutil", + "from html.parser import HTMLParser", + "from http.server import HTTPServer, SimpleHTTPRequestHandler", + "from multiprocessing import Pool", + "import typer", + "from jinja2 import Template", + "from ruff.__main__ import find_ruff_bin", + "from slugify import slugify as py_slugify", + "import random", + "import time", + "from typing import Any, cast", + "from collections.abc import Container", + "from datetime import datetime, timedelta, timezone", + "from math import ceil", + "from typing import Annotated, Any", + "from pydantic import BaseModel, BeforeValidator, SecretStr", + "from typing import Annotated, Literal", + "from collections import defaultdict", + "from collections.abc import Iterable", + "from functools import lru_cache", + "from os import sep as pathsep", + "from typing import Annotated", + "import git", + "from doc_parsing_utils import check_translation", + "from pydantic_ai import Agent", + "from rich import print", + "from scripts.doc_parsing_utils import check_translation" + ], + "arg_patterns": { + "RuntimeError": { + "occurrences": 84, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 44, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 36, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CommentsDiscussion": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsDiscussions": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PartialGitHubEvent": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_graphql_translation_discussions": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "main": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 21, + "args": 0, + "types": [] + } + ] + }, + "get_graphql_translation_discussion_comments_edges": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Comments": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PartialGitHubEventIssue": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "create_comment": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "AllDiscussionsDiscussionLabels": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Comment": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CommentsEdge": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Settings": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UpdateDiscussionComment": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CommentsData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsLabelsEdge": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AddCommentData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cast": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "subscript", + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "get_graphql_response": { + "occurrences": 21, + "arg_count": { + "min": 3, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 12, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "AddDiscussionComment": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsRepository": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AddCommentResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CommentsRepository": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_graphql_translation_discussion_comments": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "CommentsResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsLabelNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AllDiscussionsDiscussionNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "update_comment": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "UpdateCommentResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Github": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "call", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "UpdateCommentData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 70, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 70, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "str": { + "occurrences": 180, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 180, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Path": { + "occurrences": 135, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 114, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "list": { + "occurrences": 65, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 60, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Repo": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "remove_header_permalinks": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "print": { + "occurrences": 320, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 264, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 24, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 20, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "super": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "get_lang_paths": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "update_languages": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "find_ruff_bin": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "len": { + "occurrences": 200, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 148, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 24, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 20, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "app": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "get_en_url": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "sorted": { + "occurrences": 28, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "call", + "kwarg" + ] + } + ] + }, + "slugify": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "get_en_config": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "stage_zensical_docs": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "strip_markdown_links": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "any": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "call", + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "set": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "py_slugify": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "render_banner_sponsors": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "copy_zensical_stage_to_site": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_updated_config_content": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "build_zensical_config": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Template": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "VisibleTextExtractor": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "add_permalinks_page": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "get_zensical_theme_language": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "generate_docs_src_versions_for_file": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "add_markdown_notice": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Pool": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "build_zensical_lang_to_stage": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_non_translated_path": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPServer": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "render_banner_sponsors_partial": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "split_markdown_header": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "generate_readme_content": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "get_banner_sponsors": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "min": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "lit", + "call", + "expr" + ] + } + ] + }, + "get_langs": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "list_all_removable": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "list_removable": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "add_missing": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "check_translation": { + "occurrences": 6, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 6, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "range": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 2, + "types": [ + "lit", + "expr" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "get_prompt": { + "occurrences": 3, + "arg_count": { + "min": 6, + "max": 6, + "common": 6 + }, + "patterns": [ + { + "count": 3, + "args": 6, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "translate_page": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "list_outdated": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "generate_lang_path": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "update_outdated": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "iter_en_paths_to_translate": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "generate_en_path": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Agent": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_llm_translatable": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "list_missing": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "tuple": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 10, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "iter_all_en_paths": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "process_one_page": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cli": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "get_all_paths": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "iter_all_lang_paths": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "LinkData": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "next": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "Author": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_graphql_question_discussion_edges": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "timedelta": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "DiscussionsResponseData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DiscussionExpertsResults": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 6, + "common": 6 + }, + "patterns": [ + { + "count": 3, + "args": 6, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "max": { + "occurrences": 16, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "DiscussionsCommentsNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ceil": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "get_users_to_write": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "update_content": { + "occurrences": 15, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 15, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "DiscussionsResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isinstance": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "get_discussion_nodes": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "RateLimiter": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "DiscussionsNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DiscussionsEdge": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_discussions_experts": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "CommentsNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Replies": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DiscussionsComments": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DiscussionsRepository": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Discussions": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BeforeValidator": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lambda" + ] + } + ] + }, + "open": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "enumerate": { + "occurrences": 44, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 20, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "PRsRepository": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ContributorsResults": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_contributors": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "ReviewNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Reviews": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_graphql_pr_edges": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "PullRequestNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PullRequestEdge": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "LabelNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Labels": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_pr_nodes": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "PullRequests": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PRsResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PRsResponseData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_current_version": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "call", + "var" + ] + } + ] + }, + "update_release_notes": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "var", + "var", + "var", + "var" + ] + } + ] + }, + "update_version_file": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "int": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "parse_version": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ValueError": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 32, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "bump_version": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "call", + "var" + ] + } + ] + }, + "get_release_notes_body": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "call", + "var", + "var" + ] + } + ] + }, + "SponsorsUser": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_individual_sponsors": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "SponsorshipAsMaintainer": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_graphql_sponsor_edges": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "SponsorsResponseData": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Tier": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SponsorshipAsMaintainerNode": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SponsorshipAsMaintainerEdge": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SponsorsResponse": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "defaultdict": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SponsorEntity": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "extract_multiline_code_blocks": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTMLLinkAttribute": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "extract_header_permalinks": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "extract_markdown_links": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "replace_multiline_code_block": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "MarkdownLinkInfo": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 6, + "common": 6 + }, + "patterns": [ + { + "count": 3, + "args": 6, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_add_lang_code_to_url": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "replace_multiline_code_blocks_in_text": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "CodeIncludeInfo": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "replace_header_permalinks": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "extract_code_includes": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "replace_code_includes_with_placeholders": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderPermalinkInfo": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MultilineCodeBlockInfo": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HtmlLinkInfo": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "replace_markdown_links": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "var", + "var", + "var", + "var" + ] + } + ] + }, + "_construct_html_link": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "extract_html_links": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "replace_placeholders_with_code_includes": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "zip": { + "occurrences": 8, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "subscript", + "subscript", + "kwarg" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "kwarg" + ] + } + ] + }, + "_construct_markdown_link": { + "occurrences": 3, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_code_block_lang": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "replace_html_links": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "var", + "var", + "var", + "var" + ] + } + ] + }, + "_split_slashes_comment": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_split_hash_comment": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "scripts/playwright", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= (\"browser\" | \"chromium\" | \"click\" | \"close\" | \"context\" | \"get_by_label\" | \"get_by_role\" | \"goto\" | \"headless\" | \"launch\" | \"name\" | \"new_context\" | \"new_page\" | \"page\" | \"path\" | \"playwright\" | \"screenshot\" | \"viewport\")+", + "mdl_score": 1000000000000, + "imports": [ + "import subprocess", + "import time", + "import httpx", + "from playwright.sync_api import Playwright, sync_playwright" + ], + "arg_patterns": { + "range": { + "occurrences": 35, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 35, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "run": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "sync_playwright": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 21, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "scripts/playwright/separate_openapi_schemas", + "method_count": 5, + "imports": [ + "import subprocess", + "from playwright.sync_api import Playwright, sync_playwright" + ], + "arg_patterns": { + "sync_playwright": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "run": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "scripts/tests/test_translation_fixer", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= \"changing_dir\"?+ \"tmp_path\"? (\"Path\" | \"THIS_DIR\" | \"chdir\" | \"cli\" | \"copy\" | \"data_path\" | \"directory\" | \"docs_dir\" | \"en_docs_dir\" | \"en_file_path\" | \"exist_ok\" | \"exit_code\" | \"expected_content\" | \"finally\" | \"fixed_content\" | \"for\" | \"fspath\" | \"getcwd\" | \"if\" | \"in\" | \"initial_dir\" | \"invoke\" | \"is_relative_to\" | \"item\" | \"item_path\" | \"items\" | \"lang_docs_dir\" | \"mkdir\" | \"os\" | \"output\" | \"param\" | \"parents\" | \"platform\" | \"read_text\" | \"request\" | \"resolve\" | \"result\" | \"return\" | \"root_dir\" | \"runner\" | \"shutil\" | \"str\" | \"sys\" | \"translation_file_path\" | \"try\" | \"yield\")+ \"add_marker\"?+ (\"CliRunner\" | \"cwd\")?+ \"skip_on_windows\"?", + "mdl_score": 1000000000000, + "imports": [ + "import os", + "import shutil", + "import sys", + "from collections.abc import Generator", + "from contextlib import contextmanager", + "from pathlib import Path", + "import pytest", + "from typer.testing import CliRunner", + "from scripts.translation_fixer import cli" + ], + "arg_patterns": { + "Path": { + "occurrences": 45, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "str": { + "occurrences": 20, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "changing_dir": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CliRunner": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "scripts/tests/test_translation_fixer/test_code_blocks", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"Path\" | \"cli\" | \"data_path\" | \"exit_code\" | \"expected_content\" | \"fixed_content\" | \"in\" | \"invoke\" | \"not\" | \"not in\" | \"output\" | \"read_text\" | \"result\" | \"root_dir\" | \"runner\")+", + "mdl_score": 1000000000000, + "imports": [ + "from pathlib import Path", + "import pytest", + "from typer.testing import CliRunner", + "from scripts.translation_fixer import cli" + ], + "arg_patterns": { + "Path": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 36, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "scripts/tests/test_translation_fixer/test_header_permalinks", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= (\"Path\" | \"cli\" | \"data_path\" | \"exit_code\" | \"expected_content\" | \"fixed_content\" | \"in\" | \"invoke\" | \"output\" | \"read_text\" | \"result\" | \"root_dir\" | \"runner\")+", + "mdl_score": 1000000000000, + "imports": [ + "from pathlib import Path", + "import pytest", + "from typer.testing import CliRunner", + "from scripts.translation_fixer import cli" + ], + "arg_patterns": { + "Path": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "tests", + "method_count": 2036, + "algorithm": "CRX", + "grammar": "root ::= (\"@\" | \"FastAPI\" | \"TestClient\" | \"app\" | \"client\" | \"data\" | \"def\" | \"get\" | \"headers\" | \"in\" | \"json\" | \"post\" | \"pytest\" | \"raises\" | \"response\" | \"return\" | \"status_code\" | \"str\" | \"text\" | \"value\" | \"yield\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from pydantic import BaseModel", + "import http", + "from fastapi import FastAPI, Path, Query", + "from fastapi import FastAPI", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from pydantic import BaseModel, ConfigDict", + "from fastapi import APIRouter, FastAPI", + "import pytest", + "from pydantic import BaseModel, HttpUrl", + "from starlette.responses import JSONResponse", + "from fastapi.responses import JSONResponse", + "from typing import Annotated", + "from fastapi import Body, FastAPI, Query", + "from fastapi import Depends, FastAPI, Path", + "from fastapi.param_functions import Query", + "from fastapi import APIRouter, FastAPI, Query", + "from .main import app", + "from pydantic import (", + "from functools import partial", + "from typing import Any, cast", + "from fastapi import FastAPI, UploadFile", + "from fastapi._compat import (", + "from fastapi._compat.shared import is_bytes_sequence_annotation", + "from pydantic.fields import FieldInfo", + "from fastapi._compat import v2", + "from typing import Union", + "from pydantic import BaseModel, computed_field", + "from pathlib import Path", + "from fastapi import APIRouter, FastAPI, File, UploadFile", + "from fastapi.exceptions import HTTPException", + "from starlette.types import ASGIApp", + "from fastapi.routing import APIRoute", + "from pydantic import BaseModel, WithJsonSchema", + "import io", + "from typing import cast", + "from fastapi.datastructures import Default, DefaultPlaceholder", + "from datetime import datetime, timezone", + "from pydantic import field_serializer", + "from typing import Any", + "from fastapi.responses import HTMLResponse, JSONResponse, PlainTextResponse", + "from tests.utils import needs_orjson", + "import orjson # ty: ignore[unresolved-import]", + "from fastapi.dependencies.utils import get_typed_annotation", + "from typing import Annotated, Any", + "from fastapi import Depends, FastAPI, HTTPException", + "from collections.abc import Generator", + "from contextlib import contextmanager", + "from fastapi import Depends, FastAPI", + "from fastapi.responses import StreamingResponse", + "from fastapi import Depends, FastAPI, WebSocket", + "from fastapi import Depends, FastAPI, Security", + "from collections.abc import AsyncGenerator, Generator", + "import json", + "from fastapi import BackgroundTasks, Depends, FastAPI", + "from collections.abc import Awaitable, Callable", + "from contextvars import ContextVar", + "from fastapi import Depends, FastAPI, Request, Response", + "from fastapi import APIRouter, Depends, FastAPI", + "from fastapi import FastAPI, HTTPException, Security", + "from fastapi.security import (", + "from typing_extensions import TypeAliasType", + "from fastapi.security import SecurityScopes", + "import inspect", + "import sys", + "from functools import wraps", + "from fastapi.concurrency import iterate_in_threadpool, run_in_threadpool", + "from inspect import iscoroutinefunction", + "from asyncio import iscoroutinefunction", + "from fastapi import Body, Depends, FastAPI, HTTPException", + "from fastapi import APIRouter, Depends, FastAPI, HTTPException", + "from fastapi.exceptions import FastAPIError", + "from fastapi import Depends, Security", + "from fastapi import FastAPI, Request", + "import warnings", + "from fastapi.exceptions import FastAPIDeprecationWarning", + "from fastapi.responses import ORJSONResponse, UJSONResponse # ty: ignore[deprecated]", + "from tests.utils import needs_orjson, needs_ujson", + "from unittest.mock import patch", + "from fastapi import Depends, FastAPI, Query", + "from fastapi.exceptions import RequestValidationError", + "import os", + "import subprocess", + "import fastapi.cli", + "from fastapi import FastAPI, File, Form", + "from dirty_equals import HasRepr", + "from fastapi.exceptions import ResponseValidationError", + "from pydantic import BaseModel, ValidationInfo, field_validator", + "from starlette.testclient import TestClient", + "from fastapi import FastAPI, Form", + "from pydantic import BaseModel, Field", + "import errno", + "import runpy", + "from contextlib import AsyncExitStack", + "from typing import Literal", + "import anyio", + "from fastapi import APIRouter, Depends, FastAPI, HTTPException, Request, WebSocket", + "from starlette.exceptions import HTTPException as StarletteHTTPException", + "from starlette.responses import PlainTextResponse, Response", + "from starlette.routing import BaseRoute, Match, NoMatchFound, Route", + "from typing import Annotated, TypeVar", + "from fastapi.requests import HTTPConnection", + "from starlette.websockets import WebSocket", + "from fastapi import APIRouter, FastAPI, Request", + "from fastapi import APIRouter, Depends, FastAPI, Response", + "import uuid", + "from fastapi import FastAPI, Query", + "from fastapi import Cookie, FastAPI, Form, Header, Query", + "from pydantic import Json", + "from collections import deque", + "from dataclasses import dataclass", + "from decimal import Decimal", + "from enum import Enum", + "from math import isinf, isnan", + "from pathlib import PurePath, PurePosixPath, PureWindowsPath", + "from typing import TypedDict", + "from fastapi._compat import Undefined", + "from fastapi.encoders import jsonable_encoder", + "from fastapi.exceptions import PydanticV1NotSupportedError", + "from pydantic import BaseModel, Field, ValidationError", + "from pydantic import v1", + "from fastapi import FastAPI, File", + "from starlette.datastructures import UploadFile as StarletteUploadFile", + "from fastapi.openapi.docs import get_redoc_html, get_swagger_ui_html", + "from dirty_equals import IsOneOf", + "from pydantic import BaseModel, condecimal", + "from fastapi import FastAPI, File, Form, UploadFile", + "from fastapi.dependencies.utils import (", + "from fastapi import Body, Cookie, FastAPI, Header, Path, Query", + "from fastapi.openapi.models import Schema, SchemaType", + "from fastapi.responses import ORJSONResponse # ty: ignore[deprecated]", + "from sqlalchemy.sql.elements import quoted_name", + "from fastapi.params import Param", + "from fastapi import Cookie, FastAPI, Header, Path, Query", + "from fastapi.params import Body, Cookie, Header, Param, Path, Query", + "from datetime import date", + "from typer.testing import CliRunner", + "from scripts.prepare_release import (", + "from tests.utils import skip_module_if_py_gte_314", + "from pydantic.v1 import BaseModel", + "from __future__ import annotations", + "from dataclasses import dataclass, field", + "from dirty_equals import IsUUID", + "from fastapi import Cookie, FastAPI, Header, Query", + "from .utils import needs_py310", + "from fastapi import Depends, FastAPI, Response", + "from fastapi import Depends, FastAPI, Header, status", + "from fastapi import FastAPI, Path, Query, status", + "from fastapi import Body, FastAPI", + "from dirty_equals import IsPartialDict", + "from pydantic import BaseModel, ConfigDict, Field", + "from fastapi import FastAPI, Response", + "from fastapi import BackgroundTasks, Depends, FastAPI, Request, Response", + "from fastapi.exceptions import FastAPIError, ResponseValidationError", + "from fastapi.responses import JSONResponse, Response", + "from fastapi import FastAPI, Request, WebSocket, WebSocketDisconnect", + "from fastapi.routing import APIRoute, APIWebSocketRoute", + "from fastapi import APIRouter", + "from collections.abc import AsyncGenerator", + "from contextlib import asynccontextmanager", + "from typing import Annotated, cast", + "from fastapi import APIRouter, Body, Depends, FastAPI, Request, Security", + "from fastapi.openapi.utils import get_openapi", + "from fastapi.routing import (", + "from fastapi.security import HTTPBearer", + "from starlette.routing import BaseRoute, Host, Match, Mount, NoMatchFound, Route, Router", + "from tests.utils import needs_py310", + "from fastapi.security import APIKeyCookie", + "from fastapi.security import APIKeyHeader", + "from fastapi.security import APIKeyQuery", + "from fastapi import FastAPI, Security", + "from fastapi.security.http import HTTPAuthorizationCredentials, HTTPBase", + "from base64 import b64encode", + "from fastapi.security import HTTPBasic, HTTPBasicCredentials", + "from fastapi.security import HTTPAuthorizationCredentials, HTTPBearer", + "from fastapi.security import HTTPAuthorizationCredentials, HTTPDigest", + "from fastapi.security import OAuth2, OAuth2PasswordRequestFormStrict", + "from fastapi.security import OAuth2AuthorizationCodeBearer", + "from fastapi import APIRouter, Depends, FastAPI, Security", + "from fastapi.security import OAuth2PasswordBearer", + "from fastapi.security.open_id_connect_url import OpenIdConnect", + "from datetime import datetime", + "import asyncio", + "import time", + "from collections.abc import AsyncIterable, Iterable", + "import fastapi.routing", + "from fastapi.responses import EventSourceResponse", + "from fastapi.sse import ServerSentEvent", + "from fastapi import FastAPI, HTTPException", + "from typing import AsyncIterable, Iterable # noqa: UP035 to test coverage", + "from collections.abc import AsyncIterable", + "from starlette.types import Message, Scope", + "from typing import TYPE_CHECKING, Annotated", + "from .utils import needs_py314", + "from fastapi import Depends, FastAPI, Request", + "from fastapi.openapi.docs import get_swagger_ui_html", + "from typing import Annotated, Any, Literal", + "from pydantic import Tag", + "from fastapi import Body", + "from pydantic import Discriminator, Tag", + "from pydantic.dataclasses import dataclass", + "from fastapi import FastAPI, Request, WebSocket", + "from fastapi.exceptions import (", + "import functools", + "from .forward_reference_type import forwardref_method", + "from fastapi import APIRouter, Depends, FastAPI, WebSocket", + "from fastapi import (", + "from fastapi.middleware import Middleware", + "from importlib.util import find_spec" + ], + "arg_patterns": { + "Depends": { + "occurrences": 654, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 519, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 60, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 39, + "args": 2, + "types": [ + "var", + "kwarg" + ] + }, + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "FastAPI": { + "occurrences": 1053, + "arg_count": { + "min": 0, + "max": 4, + "common": 0 + }, + "patterns": [ + { + "count": 903, + "args": 0, + "types": [] + }, + { + "count": 138, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "TestClient": { + "occurrences": 1083, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 1014, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 69, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "HTTPBearer": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "snapshot": { + "occurrences": 318, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 318, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "HTTPBasic": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Security": { + "occurrences": 165, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 117, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 48, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "b64encode": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "APIRouter": { + "occurrences": 441, + "arg_count": { + "min": 0, + "max": 7, + "common": 0 + }, + "patterns": [ + { + "count": 288, + "args": 0, + "types": [] + }, + { + "count": 123, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 21, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 7, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "isinstance": { + "occurrences": 64, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 44, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 16, + "args": 2, + "types": [ + "subscript", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "APIRouteB": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIRouteC": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "APIRouteA": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 189, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 185, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Field": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "ModelWithRef": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ConfigDict": { + "occurrences": 27, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "JSONResponse": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 9, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Item": { + "occurrences": 147, + "arg_count": { + "min": 1, + "max": 4, + "common": 2 + }, + "patterns": [ + { + "count": 72, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 27, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 21, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 15, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "Schema": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "NotImplementedError": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "app": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "CustomError": { + "occurrences": 8, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Header": { + "occurrences": 48, + "arg_count": { + "min": 0, + "max": 3, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + }, + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "WebSocket": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + } + ] + }, + "make_app": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "call_next": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Middleware": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "repr": { + "occurrences": 112, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 108, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "middleware_func": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "MyModel": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OpenIdConnect": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "User": { + "occurrences": 78, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 45, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 15, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Query": { + "occurrences": 126, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 36, + "args": 0, + "types": [] + }, + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "OAuth2AuthorizationCodeBearer": { + "occurrences": 12, + "arg_count": { + "min": 3, + "max": 4, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "get_client": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + } + ] + }, + "Form": { + "occurrences": 75, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 72, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "getattr": { + "occurrences": 20, + "arg_count": { + "min": 2, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 8, + "args": 3, + "types": [ + "var", + "lit", + "lit" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "var", + "lit", + "other" + ] + } + ] + }, + "print": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "len": { + "occurrences": 76, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 60, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ServerSentEvent": { + "occurrences": 42, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "other" + ] + } + ] + }, + "PersonBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Person": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PersonCreate": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PersonRead": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPBase": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "File": { + "occurrences": 42, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 36, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "other", + "kwarg" + ] + } + ] + }, + "vars": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TypeError": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "SomeCustomClass": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MyUuid": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "field_serializer": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "type": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "str": { + "occurrences": 175, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 90, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 75, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "APIKeyQuery": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "acquire_session": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Session": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "ValueError": { + "occurrences": 20, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "ResponseModel": { + "occurrences": 5, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ExtendedItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_swagger_ui_html": { + "occurrences": 15, + "arg_count": { + "min": 2, + "max": 5, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 5, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "bytes": { + "occurrences": 45, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 45, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "CallableDependency": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "CallableGenDependency": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "AsyncCallableGenDependency": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "MethodsDependency": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "instance": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "next": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 8, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + } + ] + }, + "AsyncCallableDependency": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "cast": { + "occurrences": 33, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 21, + "args": 2, + "types": [ + "var", + "subscript" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "var", + "expr" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "var", + "call" + ] + } + ] + }, + "is_uploadfile_sequence_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "FieldInfo": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Missing": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Model": { + "occurrences": 17, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "is_bytes_sequence_annotation": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "EmbeddedModel": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Model2": { + "occurrences": 11, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Model3": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Model1": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Cookie": { + "occurrences": 39, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + }, + { + "count": 9, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "object": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "ForwardRefModel": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OverrideResponse": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "condecimal": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 15, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 15, + "args": 4, + "types": [ + "other", + "other", + "other", + "other" + ] + } + ] + }, + "Decimal": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Facility": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Address": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "JsonApiResponse": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Error": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "JsonApiError": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Body": { + "occurrences": 66, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 15, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "OtherDependencyError": { + "occurrences": 19, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "AsyncDependencyError": { + "occurrences": 7, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SyncDependencyError": { + "occurrences": 7, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsPartialDict": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "PetDB": { + "occurrences": 20, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 18, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserDB": { + "occurrences": 14, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PetOut": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserCreate": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "WithJsonSchema": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "HeaderRouter": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "list": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 20, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "super": { + "occurrences": 20, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 20, + "args": 0, + "types": [] + } + ] + }, + "Route": { + "occurrences": 27, + "arg_count": { + "min": 2, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 15, + "args": 3, + "types": [ + "lit", + "var", + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "Router": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "Subscription": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "set": { + "occurrences": 40, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "iter_route_contexts": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_iter_included_route_candidates": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "NoMatchFound": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "PlainTextResponse": { + "occurrences": 42, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "dict": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "get_openapi": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 4, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "AssertionError": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "UnknownRoute": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TrackingRouter": { + "occurrences": 7, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "handler": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Host": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "lit", + "var", + "kwarg" + ] + } + ] + }, + "HeaderRoute": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RejectingRoute": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TrackingRoute": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Mount": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + } + ] + }, + "sorted": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_restore_fastapi_scope_key": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "lit", + "call" + ] + } + ] + }, + "write_file": { + "occurrences": 189, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 183, + "args": 2, + "types": [ + "expr", + "lit" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "expr", + "var" + ] + } + ] + }, + "AsyncExitStack": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "HTTPException": { + "occurrences": 39, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 18, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 15, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "OSError": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "lit", + "lit" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "hasattr": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "Path": { + "occurrences": 120, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 27, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 21, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 15, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "record_dependency": { + "occurrences": 21, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 21, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "PartialRoute": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "response": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "Default": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "UploadFile": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "StarletteHTTPException": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "jsonable_encoder": { + "occurrences": 165, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 87, + "args": 2, + "types": [ + "var", + "kwarg" + ] + }, + { + "count": 72, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + } + ] + }, + "ModelWithPath": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isinf": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "ModelWithConfig": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MyDict": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelV1": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ModelWithAlias": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PurePath": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "Unserializable": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "__import__": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "Color": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "datetime": { + "occurrences": 87, + "arg_count": { + "min": 3, + "max": 4, + "common": 3 + }, + "patterns": [ + { + "count": 78, + "args": 3, + "types": [ + "lit", + "lit", + "lit" + ] + }, + { + "count": 9, + "args": 4, + "types": [ + "lit", + "lit", + "lit", + "lit" + ] + } + ] + }, + "DictablePerson": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Pet": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "ModelWithCustomEncoder": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "custom_enum_encoder": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "safe_datetime": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PureWindowsPath": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "PurePosixPath": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "isnan": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "ModelWithCustomEncoderSubclass": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelWithDefault": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "DictablePet": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MyEnum": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RoleEnum": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "deque": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Product": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuth2": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "APIKeyHeader": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "CompanyForm": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "UserForm": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Rectangle": { + "occurrences": 7, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SubItem": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_app_client": { + "occurrences": 36, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "WithComputedField": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OAuth2PasswordBearer": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "create_dependency": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "create_app": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Items": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FooBaseModel": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Foo": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "dep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "hash": { + "occurrences": 32, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 32, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ContextVar": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + }, + "NamedSession": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "UserBase": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "partial": { + "occurrences": 39, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 27, + "args": 2, + "types": [ + "var", + "lit" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "DummyClient": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "get_parameterless_without_scopes": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "issubclass": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "Message": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ORJSONResponse": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_make_ujson_app": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "UJSONResponse": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "_make_orjson_app": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "iter_data": { + "occurrences": 27, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 27, + "args": 0, + "types": [] + } + ] + }, + "StreamingResponse": { + "occurrences": 27, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 27, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "APIKeyCookie": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "TypeAliasType": { + "occurrences": 3, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "lit", + "subscript", + "kwarg" + ] + } + ] + }, + "Shop": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "release_notes_content": { + "occurrences": 33, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_release_notes_body": { + "occurrences": 15, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 15, + "args": 3, + "types": [ + "var", + "lit", + "call" + ] + } + ] + }, + "bump_version": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "update_version_file": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "lit", + "call" + ] + } + ] + }, + "date": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "lit", + "lit", + "lit" + ] + } + ] + }, + "CliRunner": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "update_release_notes": { + "occurrences": 6, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 6, + "args": 4, + "types": [ + "var", + "lit", + "call", + "call" + ] + } + ] + }, + "ModelB": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelC": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelA": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HasRepr": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "field_validator": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "TypeVar": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "PlatformRole": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "OtherRole": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "ResponseLevel3": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseLevel1": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseLevel5": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseLevel2": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseLevel0": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseLevel4": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "field": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "IsUUID": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Coordinate": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ItemGroup": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HTTPDigest": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ReturnModelV1": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ResponseModelV1": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ErrorModelV1": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelV1A": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "skip_module_if_py_gte_314": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ParamModelV1": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "any": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "expr", + "other" + ] + } + ] + }, + "Param": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "new_subscription": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "ModelWithDatetimeField": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "OtherItem": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "map": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "call" + ] + } + ] + }, + "f": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "passthrough": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "RequestValidationError": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "ExceptionCapture": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Tag": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "FirstItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RuntimeError": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "raise_value_error": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "_run_asgi_and_cancel": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "lit", + "kwarg" + ] + } + ] + }, + "float": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Dog": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Cat": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Discriminator": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_typed_annotation": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "call" + ] + } + ] + }, + "globals": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "AuthHeaders": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "original_read": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "ord": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "quoted_name": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "DBUser": { + "occurrences": 40, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 39, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Response": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + } + ] + }, + "BaseUser": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "noop_wrap": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "dunder_call": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "noop_wrap_async": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ClassInstanceAsyncDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "func": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "ClassInstanceWrappedGenDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "wraps": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ClassInstanceAsyncWrappedDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ClassInstanceWrappedDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ClassInstanceWrappedAsyncGenDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ClassInstanceWrappedAsyncDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ClassInstanceAsyncWrappedGenAsyncDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "iterate_in_threadpool": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ClassInstanceDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ClassInstanceGenDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ClassInstanceAsyncWrappedAsyncDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "iscoroutinefunction": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ClassInstanceAsyncWrappedGenDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "run_in_threadpool": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + } + ] + }, + "ClassInstanceAsyncGenDep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "PlainSerializer": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lambda" + ] + } + ] + }, + "TypeAdapter": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FakeNumpyArray": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "find_spec": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "open": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "receive": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "State": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelNoAlias": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Dep": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "get_redoc_html": { + "occurrences": 12, + "arg_count": { + "min": 2, + "max": 4, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "FormModelExtraAllow": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModel": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MessageOutput": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MessageEvent": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "MessageEventType": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "InvoiceEventReceived": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Event": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Invoice": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "InvoiceEvent": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelDefaults": { + "occurrences": 13, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ModelSubclass": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "SubModel": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CustomModel": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "patch": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "tests/benchmarks", + "method_count": 48, + "algorithm": "CRX", + "grammar": "root ::= (\"LARGE_PAYLOAD\" | \"_bench_get\" | \"_bench_post_json\" | \"benchmark\" | \"body\" | \"bytes\" | \"client\" | \"content\" | \"def\" | \"do_request\" | \"get\" | \"int\" | \"json\" | \"path\" | \"post\" | \"response\" | \"return\" | \"status_code\" | \"tuple\" | \"warmup\")+ \"ItemOut\"?+ \"_expected_large_payload_json_bytes\"?+ \"len\"?+ \"LargeOut\"?+ (\"item\" | \"name\" | \"value\")?+ \"payload\"? \"dep\"?+ \"items\"? \"LARGE_ITEMS\"? \"metadata\"? \"LARGE_METADATA\"?", + "mdl_score": 1000000000000, + "imports": [ + "import json", + "import sys", + "from collections.abc import Iterator", + "from typing import Annotated, Any", + "import pytest", + "from fastapi import Depends, FastAPI", + "from fastapi.testclient import TestClient", + "from pydantic import BaseModel" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_expected_large_payload_json_bytes": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + } + ] + }, + "Depends": { + "occurrences": 27, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 27, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_bench_post_json": { + "occurrences": 12, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 12, + "args": 4, + "types": [ + "var", + "var", + "lit", + "kwarg" + ] + } + ] + }, + "_bench_get": { + "occurrences": 48, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 48, + "args": 3, + "types": [ + "var", + "var", + "lit" + ] + } + ] + }, + "len": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "LargeOut": { + "occurrences": 13, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ItemOut": { + "occurrences": 19, + "arg_count": { + "min": 1, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 18, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "ItemIn": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "list": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "range": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "benchmark": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "LargeIn": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_modules_same_name_body", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"data\" | \"get\" | \"json\" | \"path\" | \"post\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"? \"snapshot\"?+ \"a\"? \"b\"?", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import APIRouter, Body", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from .app.main import app" + ], + "arg_patterns": { + "APIRouter": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Body": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_body", + "method_count": 113, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"body_model_name\" | \"client\" | \"get_body_model_name\" | \"json\" | \"openapi\" | \"path\" | \"post\" | \"response\" | \"status_code\" | \"text\")?+ \"IsOneOf\"?+ \"return\"? \"p\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from dirty_equals import IsOneOf, IsPartialDict", + "from fastapi import Body, FastAPI", + "from fastapi.testclient import TestClient", + "from pydantic import BaseModel, Field", + "from .utils import get_body_model_name", + "from typing import Annotated, Any", + "from dirty_equals import IsOneOf", + "from typing import Any" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 192, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 192, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelOptionalStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "get_body_model_name": { + "occurrences": 48, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 48, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "BodyModelOptionalAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Body": { + "occurrences": 48, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "BodyModelOptionalAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Field": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "BodyModelOptionalValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 72, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 45, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 24, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "lit", + "call" + ] + } + ] + }, + "BodyModelRequiredListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsPartialDict": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "BodyModelRequiredListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelRequiredListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelRequiredListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelRequiredAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelRequiredStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelRequiredAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelRequiredValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelOptionalListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelOptionalListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelOptionalListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "BodyModelOptionalListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_cookie", + "method_count": 48, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"cookies\" | \"get\" | \"openapi\" | \"path\" | \"response\" | \"set\" | \"status_code\" | \"text\")?+ \"return\"? \"json\"?+ \"snapshot\"?+ \"p\"?+ \"IsOneOf\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from fastapi import Cookie, FastAPI", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from pydantic import BaseModel, Field", + "from dirty_equals import IsOneOf" + ], + "arg_patterns": { + "IsOneOf": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "CookieModelRequiredStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TestClient": { + "occurrences": 72, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 72, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CookieModelRequiredAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Cookie": { + "occurrences": 48, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 30, + "args": 0, + "types": [] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Field": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + } + ] + }, + "snapshot": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "CookieModelRequiredValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CookieModelRequiredAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CookieModelOptionalAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CookieModelOptionalStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CookieModelOptionalValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "CookieModelOptionalAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_file", + "method_count": 97, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"body_model_name\" | \"client\" | \"files\" | \"get_body_model_name\" | \"openapi\" | \"path\" | \"post\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"? \"json\"?+ \"len\"?+ (\"file\" | \"for\" | \"if\" | \"in\" | \"p\" | \"size\")?+ \"else\"?", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from fastapi import FastAPI, File, UploadFile", + "from fastapi.testclient import TestClient", + "from .utils import get_body_model_name", + "from typing import Any" + ], + "arg_patterns": { + "len": { + "occurrences": 64, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 64, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "File": { + "occurrences": 96, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 24, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "TestClient": { + "occurrences": 144, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 144, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "get_body_model_name": { + "occurrences": 48, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 48, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_form", + "method_count": 97, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"body_model_name\" | \"client\" | \"data\" | \"get_body_model_name\" | \"openapi\" | \"path\" | \"post\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"? \"json\"?+ \"p\"?+ \"IsOneOf\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from dirty_equals import IsOneOf, IsPartialDict", + "from fastapi import FastAPI, Form", + "from fastapi.testclient import TestClient", + "from pydantic import BaseModel, Field", + "from .utils import get_body_model_name", + "from dirty_equals import IsOneOf", + "from typing import Any" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 144, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 144, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelOptionalListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Form": { + "occurrences": 96, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 60, + "args": 0, + "types": [] + }, + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "get_body_model_name": { + "occurrences": 48, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 48, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Field": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "FormModelOptionalListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelOptionalListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "FormModelOptionalListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelOptionalAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelOptionalAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelOptionalValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelOptionalStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 48, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 45, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "lit", + "call" + ] + } + ] + }, + "FormModelRequiredValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FormModelRequiredListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsPartialDict": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_header", + "method_count": 96, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"headers\" | \"openapi\" | \"path\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"? \"json\"?+ \"snapshot\"?+ \"p\"?+ \"AnyThing\"? \"IsOneOf\"?+ \"IsPartialDict\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from dirty_equals import AnyThing, IsOneOf, IsPartialDict", + "from fastapi import FastAPI, Header", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from pydantic import BaseModel, Field" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 48, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 144, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 144, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Header": { + "occurrences": 96, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 60, + "args": 0, + "types": [] + }, + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "Field": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "HeaderModelOptionalListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelOptionalListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "HeaderModelOptionalListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelOptionalListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "lit", + "call" + ] + } + ] + }, + "IsPartialDict": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "HeaderModelRequiredAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelRequiredListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelOptionalValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelOptionalAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelOptionalAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "HeaderModelOptionalStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_path", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"openapi\" | \"path\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"? \"snapshot\"?+ \"json\"?+ \"p\"? (\"Is\" | \"expected_title\")?+ \"expected_name\"?", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from fastapi import FastAPI, Path", + "from fastapi.testclient import TestClient", + "from inline_snapshot import Is, snapshot" + ], + "arg_patterns": { + "Path": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Is": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "tests/test_request_params/test_query", + "method_count": 96, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"openapi\" | \"path\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"? \"snapshot\"?+ \"json\"?+ \"p\"?+ \"IsOneOf\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from typing import Annotated", + "import pytest", + "from dirty_equals import IsOneOf", + "from fastapi import FastAPI, Query", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from pydantic import BaseModel, Field" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 48, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Query": { + "occurrences": 90, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 54, + "args": 0, + "types": [] + }, + { + "count": 24, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + } + ] + }, + "QueryModelRequiredAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 48, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 48, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 144, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 144, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelRequiredAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Field": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 12, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + } + ] + }, + "QueryModelRequiredValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelRequiredStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "class": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelRequiredListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelRequiredListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelRequiredListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelRequiredListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalListAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalListValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalListAliasAndValidationAlias": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "QueryModelOptionalListStr": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial", + "method_count": 16, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"content\" | \"copytree\" | \"docs_src\" | \"from\" | \"get\" | \"headers\" | \"if\" | \"import\" | \"in\" | \"isdir\" | \"json\" | \"not\" | \"not in\" | \"openapi_schema\" | \"options\" | \"os\" | \"path\" | \"post\" | \"print\" | \"put\" | \"response\" | \"rmtree\" | \"shutil\" | \"snapshot\" | \"status_code\" | \"templates\" | \"text\" | \"tutorial001_py310\")?+ \"await\"? \"cookies\"? \"test_root\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import pytest", + "from docs_src.async_tests.app_a_py310.test_main import test_root", + "from fastapi.testclient import TestClient", + "from docs_src.cors.tutorial001_py310 import app", + "from inline_snapshot import snapshot", + "from docs_src.extending_openapi.tutorial001_py310 import app", + "from docs_src.middleware.tutorial001_py310 import app", + "from docs_src.response_change_status_code.tutorial001_py310 import app", + "from docs_src.response_cookies.tutorial001_py310 import app", + "from docs_src.response_cookies.tutorial002_py310 import app", + "from docs_src.response_headers.tutorial001_py310 import app", + "from docs_src.response_headers.tutorial002_py310 import app", + "import os", + "import shutil", + "from tests.utils import workdir_lock", + "from docs_src.templates.tutorial001_py310 import app", + "from docs_src.using_request_directly.tutorial001_py310 import app", + "from docs_src.wsgi.tutorial001_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 33, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 33, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "print": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "test_root": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_additional_responses", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= \"shutil\"? \"copy\"?+ (\"TestClient\" | \"app\" | \"clear\" | \"client\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"len\" | \"mod\" | \"param\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"content\"? \"json\"?+ \"os\"? \"snapshot\"?+ \"remove\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.additional_responses.tutorial001_py310 import app", + "import importlib", + "import os", + "import shutil", + "import pytest", + "from tests.utils import needs_py310, workdir_lock", + "from docs_src.additional_responses.tutorial003_py310 import app" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "len": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_additional_status_codes", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_advanced_middleware", + "method_count": 4, + "imports": [ + "from fastapi.testclient import TestClient", + "from docs_src.advanced_middleware.tutorial001_py310 import app", + "from docs_src.advanced_middleware.tutorial002_py310 import app", + "from fastapi.responses import PlainTextResponse", + "from docs_src.advanced_middleware.tutorial003_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "var", + "kwarg" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "PlainTextResponse": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "expr", + "kwarg" + ] + } + ] + }, + "int": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "subscript" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_authentication_error_status_code", + "method_count": 4, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_background_tasks", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"Path\" | \"if\" | \"is_file\" | \"log\" | \"os\" | \"remove\")?+ (\"TestClient\" | \"app\" | \"client\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"json\"?+ \"open\"?+ (\"f\" | \"in\")?+ \"read\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import os", + "from pathlib import Path", + "from fastapi.testclient import TestClient", + "from docs_src.background_tasks.tutorial001_py310 import app", + "from tests.utils import workdir_lock", + "import importlib", + "import pytest", + "from tests.utils import needs_py310, workdir_lock" + ], + "arg_patterns": { + "open": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Path": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_behind_a_proxy", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"get\" | \"response\" | \"status_code\")+ \"json\"?+ \"headers\"? \"snapshot\"?+", + "mdl_score": 152079640, + "imports": [ + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.behind_a_proxy.tutorial001_py310 import app", + "from docs_src.behind_a_proxy.tutorial001_01_py310 import app", + "from docs_src.behind_a_proxy.tutorial002_py310 import app", + "from docs_src.behind_a_proxy.tutorial003_py310 import app", + "from docs_src.behind_a_proxy.tutorial004_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "var", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + }, + "snapshot": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_bigger_applications", + "method_count": 26, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"post\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"json\"?+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_body", + "method_count": 32, + "algorithm": "CRX", + "grammar": "root ::= \"patch\"?+ \"side_effect\"? \"Exception\"?+ (\"TestClient\" | \"app\" | \"client\" | \"content\" | \"data\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"params\" | \"post\" | \"price\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "from unittest.mock import patch", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "patch": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_body_fields", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_body_multiple_params", + "method_count": 35, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"params\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_body_nested_models", + "method_count": 44, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? (\"IsList\" | \"TestClient\" | \"app\" | \"check_order\" | \"client\" | \"data\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"mod_name\" | \"param\" | \"post\" | \"put\" | \"request\" | \"response\" | \"return\" | \"startswith\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "from typing import Any", + "import pytest", + "from dirty_equals import IsList", + "from fastapi.testclient import TestClient", + "from inline_snapshot import Is, snapshot", + "from ...utils import needs_py310", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "IsList": { + "occurrences": 12, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 12, + "args": 3, + "types": [ + "lit", + "lit", + "kwarg" + ] + } + ] + }, + "Is": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_body_updates", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"patch\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_conditional_openapi", + "method_count": 4, + "imports": [ + "import importlib", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.conditional_openapi import tutorial001_py310" + ], + "arg_patterns": { + "get_client": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_configure_swagger_ui", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"get\" | \"in\" | \"not\" | \"not in\" | \"response\" | \"status_code\" | \"text\")+ \"json\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi.testclient import TestClient", + "from docs_src.configure_swagger_ui.tutorial001_py310 import app", + "from docs_src.configure_swagger_ui.tutorial002_py310 import app", + "from docs_src.configure_swagger_ui.tutorial003_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_cookie_param_models", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"c\" | \"client\" | \"cookies\" | \"get\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"request\" | \"response\" | \"return\" | \"set\" | \"status_code\" | \"text\")+ \"json\"?+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_cookie_params", + "method_count": 3, + "imports": [ + "import importlib", + "from types import ModuleType", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "other", + "kwarg" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_custom_docs_ui", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= (\"Path\" | \"TestClient\" | \"app\" | \"client\" | \"custom_docs_ui\" | \"docs_src\" | \"exist_ok\" | \"from\" | \"get\" | \"getcwd\" | \"import\" | \"in\" | \"mkdir\" | \"os\" | \"print\" | \"response\" | \"static_dir\" | \"status_code\" | \"text\" | \"tutorial001_py310\" | \"tutorial002_py310\" | \"yield\")+ (\"json\" | \"rmdir\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import os", + "from pathlib import Path", + "import pytest", + "from fastapi.testclient import TestClient", + "from tests.utils import workdir_lock", + "from docs_src.custom_docs_ui.tutorial001_py310 import app", + "from docs_src.custom_docs_ui.tutorial002_py310 import app" + ], + "arg_patterns": { + "Path": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "print": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_custom_request_and_route", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= (\"@\" | \"Request\" | \"TestClient\" | \"__name__\" | \"app\" | \"async\" | \"body\" | \"check_gzip_request\" | \"client\" | \"compress\" | \"content\" | \"data\" | \"def\" | \"dumps\" | \"encode\" | \"float\" | \"get\" | \"gzip\" | \"headers\" | \"if\" | \"import_module\" | \"importlib\" | \"in\" | \"json\" | \"mod\" | \"n\" | \"not\" | \"not in\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"type\")+ \"IsOneOf\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import gzip", + "import importlib", + "import json", + "import pytest", + "from fastapi import Request", + "from fastapi.testclient import TestClient", + "from tests.utils import needs_py310", + "from dirty_equals import IsOneOf" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "type": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "float": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "subscript" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_custom_response", + "method_count": 25, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? (\"Any\" | \"Is\" | \"Path\" | \"TestClient\" | \"app\" | \"cast\" | \"client\" | \"content\" | \"else\" | \"fake_content\" | \"file_path\" | \"follow_redirects\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"mod_name\" | \"param\" | \"request\" | \"response\" | \"response_content\" | \"return\" | \"snapshot\" | \"some_file_path\" | \"startswith\" | \"status_code\" | \"str\" | \"test_content\" | \"text\" | \"tmp_path\" | \"tutorial008_py310\" | \"tutorial009_py310\" | \"tutorial009b_py310\" | \"write_bytes\")+ (\"headers\" | \"html_contents\")?", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "import warnings", + "from fastapi.exceptions import FastAPIDeprecationWarning", + "from docs_src.custom_response.tutorial001b_py310 import app", + "from inline_snapshot import Is, snapshot", + "from docs_src.custom_response.tutorial005_py310 import app", + "from docs_src.custom_response.tutorial006_py310 import app", + "from docs_src.custom_response.tutorial006b_py310 import app", + "from docs_src.custom_response.tutorial006c_py310 import app", + "from docs_src.custom_response.tutorial007_py310 import app", + "from pathlib import Path", + "from typing import Any, cast", + "from docs_src.custom_response import tutorial008_py310", + "from docs_src.custom_response.tutorial008_py310 import app", + "from docs_src.custom_response import tutorial009_py310", + "from docs_src.custom_response.tutorial009_py310 import app", + "from docs_src.custom_response import tutorial009b_py310", + "from docs_src.custom_response.tutorial009b_py310 import app", + "from docs_src.custom_response.tutorial009c_py310 import app" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 27, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Is": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TestClient": { + "occurrences": 39, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "str": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cast": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_dataclasses", + "method_count": 11, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"clear\" | \"client\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import needs_py310", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_debugging", + "method_count": 5, + "imports": [ + "import importlib", + "import runpy", + "import sys", + "from unittest import mock", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_dependencies", + "method_count": 51, + "algorithm": "CRX", + "grammar": "root ::= (\"@\" | \"Annotated\" | \"Any\" | \"Depends\" | \"FastAPI\" | \"Mock\" | \"TestClient\" | \"app\" | \"async\" | \"asynccontextmanager\" | \"c\" | \"client\" | \"cm\" | \"create\" | \"db_session\" | \"def\" | \"exc_info\" | \"expected_status\" | \"get\" | \"get_db\" | \"headers\" | \"import_module\" | \"importlib\" | \"is\" | \"json\" | \"mod\" | \"param\" | \"patch\" | \"path\" | \"pytest\" | \"raise_server_exceptions\" | \"raises\" | \"read_root\" | \"request\" | \"response\" | \"return\" | \"return_value\" | \"status_code\" | \"str\" | \"text\" | \"value\")+ (\"args\" | \"expected_response\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310", + "import asyncio", + "from contextlib import asynccontextmanager", + "from unittest.mock import Mock, patch", + "from docs_src.dependencies.tutorial007_py310 import get_db", + "import sys", + "from types import ModuleType", + "from typing import Annotated, Any", + "from fastapi import Depends, FastAPI", + "from fastapi.exceptions import FastAPIError", + "from docs_src.dependencies.tutorial010_py310 import get_db" + ], + "arg_patterns": { + "patch": { + "occurrences": 15, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 15, + "args": 3, + "types": [ + "lit", + "kwarg", + "kwarg" + ] + } + ] + }, + "str": { + "occurrences": 20, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 20, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Mock": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + } + ] + }, + "Depends": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "TestClient": { + "occurrences": 54, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 42, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "other", + "kwarg" + ] + } + ] + }, + "snapshot": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "asynccontextmanager": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cm": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "test_async_gen": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_encoder", + "method_count": 5, + "imports": [ + "import importlib", + "from types import ModuleType", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_events", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"pytest\"? \"warns\"?+ \"DeprecationWarning\"?+ \"from\"? \"docs_src\"?+ \"events\"?+ (\"tutorial001_py310\" | \"tutorial002_py310\")?+ \"import\"? (\"TestClient\" | \"app\" | \"client\" | \"fake_answer_to_everything_ml_model\" | \"get\" | \"json\" | \"ml_models\" | \"not\" | \"params\" | \"response\" | \"status_code\" | \"text\" | \"yield\")+ \"snapshot\"?+ \"open\"?+ (\"in\" | \"log\")?+ \"read\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import pytest", + "from fastapi import FastAPI", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.events.tutorial001_py310 import app", + "from tests.utils import workdir_lock", + "from docs_src.events.tutorial002_py310 import app", + "from docs_src.events.tutorial003_py310 import (" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "open": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_extra_data_types", + "method_count": 3, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_extra_models", + "method_count": 13, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+ \"IsList\"?+ \"check_order\"?", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from dirty_equals import IsList", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "IsList": { + "occurrences": 3, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 3, + "args": 4, + "types": [ + "lit", + "lit", + "lit", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_first_steps", + "method_count": 3, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_generate_clients", + "method_count": 13, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"dumps\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"loads\" | \"mod\" | \"modified_openapi\" | \"openapi\" | \"openapi_json\" | \"param\" | \"patch\" | \"post\" | \"read_text\" | \"request\" | \"response\" | \"return\" | \"return_value\" | \"status_code\" | \"text\" | \"tmp_file\" | \"tmp_path\" | \"tutorial003_py310\" | \"write_text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.generate_clients.tutorial002_py310 import app", + "from docs_src.generate_clients.tutorial003_py310 import app", + "import json", + "import pathlib", + "from unittest.mock import patch", + "from docs_src.generate_clients import tutorial003_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "patch": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "lit", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_graphql", + "method_count": 3, + "imports": [ + "import warnings", + "import pytest", + "from inline_snapshot import snapshot", + "from starlette.testclient import TestClient", + "from docs_src.graphql_.tutorial001_py310 import app # noqa: E402" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_handling_errors", + "method_count": 20, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"data\" | \"get\" | \"headers\" | \"in\" | \"is\" | \"json\" | \"post\" | \"response\" | \"status_code\" | \"text\")+ (\"content\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.handling_errors.tutorial001_py310 import app", + "from docs_src.handling_errors.tutorial002_py310 import app", + "from docs_src.handling_errors.tutorial003_py310 import app", + "from docs_src.handling_errors.tutorial004_py310 import app", + "from docs_src.handling_errors.tutorial005_py310 import app", + "from docs_src.handling_errors.tutorial006_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_header_param_models", + "method_count": 19, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"clear\" | \"client\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"json\"?+ \"snapshot\"?+ \"IsOneOf\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from dirty_equals import IsOneOf", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "IsOneOf": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_header_params", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"expected_status\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"path\" | \"request\" | \"response\" | \"return\" | \"status_code\")+ \"json\"?+ (\"expected_response\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_json_base64_bytes", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_metadata", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"get\" | \"in\" | \"response\" | \"status_code\" | \"text\")+ \"json\"?+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.metadata.tutorial001_py310 import app", + "from docs_src.metadata.tutorial001_1_py310 import app", + "from docs_src.metadata.tutorial002_py310 import app", + "from docs_src.metadata.tutorial003_py310 import app", + "from docs_src.metadata.tutorial004_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_openapi_callbacks", + "method_count": 5, + "imports": [ + "import importlib", + "from types import ModuleType", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_openapi_webhooks", + "method_count": 3, + "imports": [ + "from fastapi.routing import APIRoute", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.openapi_webhooks.tutorial001_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isinstance": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_path_operation_advanced_configurations", + "method_count": 18, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"clear\" | \"client\" | \"content\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\" | \"yaml_data\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.path_operation_advanced_configuration.tutorial001_py310 import app", + "from docs_src.path_operation_advanced_configuration.tutorial002_py310 import app", + "from docs_src.path_operation_advanced_configuration.tutorial003_py310 import app", + "import importlib", + "import pytest", + "from ...utils import needs_py310", + "from docs_src.path_operation_advanced_configuration.tutorial005_py310 import app", + "from docs_src.path_operation_advanced_configuration.tutorial006_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_path_operation_configurations", + "method_count": 20, + "algorithm": "CRX", + "grammar": "root ::= (\"DESCRIPTIONS\" | \"Is\" | \"TestClient\" | \"app\" | \"client\" | \"expected_status\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"mod_name\" | \"param\" | \"path\" | \"post\" | \"request\" | \"response\" | \"return\" | \"snapshot\" | \"status_code\" | \"text\")+ \"IsList\"?+ \"expected_response\"? \"check_order\"?", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from dirty_equals import IsList", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310", + "from docs_src.path_operation_configuration.tutorial002b_py310 import app", + "from textwrap import dedent", + "from inline_snapshot import Is, snapshot", + "from docs_src.path_operation_configuration.tutorial006_py310 import app" + ], + "arg_patterns": { + "IsList": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "lit", + "lit", + "kwarg" + ] + } + ] + }, + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Is": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "dedent": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_path_params", + "method_count": 18, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"content\" | \"get\" | \"item_id\" | \"print\" | \"response\" | \"status_code\" | \"text\" | \"user_id\")?+ \"asyncio\"? \"json\"?+ \"run\"?+ (\"expected_response\" | \"snapshot\")?+ \"read_users2\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.path_params.tutorial001_py310 import app", + "from docs_src.path_params.tutorial002_py310 import app", + "from docs_src.path_params.tutorial003_py310 import app", + "import asyncio", + "from docs_src.path_params.tutorial003b_py310 import app, read_users2", + "from docs_src.path_params.tutorial004_py310 import app", + "from docs_src.path_params.tutorial005_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "read_users2": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "print": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_path_params_numeric_validations", + "method_count": 29, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"request\" | \"return\")?+ (\"client\" | \"get\" | \"path\" | \"response\" | \"status_code\" | \"text\")?+ \"app\"? \"json\"?+ (\"expected_response\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_python_types", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= (\"get_items\" | \"res\")?+ (\"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"request\" | \"return\")?+ \"say_hello\"?+ \"pytest\"? \"patch\"?+ \"get_person_name\"?+ \"raises\"?+ (\"arg\" | \"args\" | \"call_args\" | \"call_args_list\" | \"call_count\" | \"for\" | \"in\" | \"items_s\" | \"items_t\" | \"mock_print\" | \"module\" | \"module_name\" | \"process_item\" | \"process_items\" | \"run_module\" | \"run_name\" | \"runpy\" | \"say_hi\" | \"str\")?+ \"Person\"?+ \"TypeError\"?+ \"assert_called_with\"?+ \"get_name_with_age\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import runpy", + "from unittest.mock import patch", + "import pytest", + "from docs_src.python_types.tutorial003_py310 import get_name_with_age", + "from docs_src.python_types.tutorial004_py310 import get_name_with_age", + "from docs_src.python_types.tutorial005_py310 import get_items", + "from docs_src.python_types.tutorial006_py310 import process_items", + "from docs_src.python_types.tutorial007_py310 import process_items", + "from docs_src.python_types.tutorial008_py310 import process_items", + "import importlib", + "from types import ModuleType", + "from ...utils import needs_py310", + "from docs_src.python_types.tutorial010_py310 import Person, get_person_name", + "from docs_src.python_types.tutorial013_py310 import say_hello" + ], + "arg_patterns": { + "say_hello": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_name_with_age": { + "occurrences": 9, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 9, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "process_items": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "patch": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_items": { + "occurrences": 3, + "arg_count": { + "min": 9, + "max": 9, + "common": 9 + }, + "patterns": [ + { + "count": 3, + "args": 9, + "types": [ + "lit", + "lit", + "other", + "lit", + "other", + "lit", + "other", + "lit", + "other" + ] + } + ] + }, + "str": { + "occurrences": 5, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 5, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "get_person_name": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "Person": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_query_param_models", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"params\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"json\"?+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_query_params", + "method_count": 19, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"c\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"path\" | \"request\" | \"response\" | \"return\" | \"status_code\")+ \"json\"?+ (\"expected_json\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310", + "from docs_src.query_params.tutorial005_py310 import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_query_params_str_validations", + "method_count": 81, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"params\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\" | \"url\")+ \"json\"?+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310", + "from fastapi._compat import PYDANTIC_VERSION_MINOR_TUPLE", + "from inline_snapshot import Is, snapshot", + "from dirty_equals import IsStr" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 51, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 51, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 48, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "IsStr": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Is": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_request_files", + "method_count": 31, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"default_pydantic_max_size\" | \"file\" | \"file2\" | \"files\" | \"get\" | \"import_module\" | \"importlib\" | \"in\" | \"json\" | \"mod\" | \"open\" | \"param\" | \"path\" | \"path2\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\" | \"tmp_path\" | \"write_bytes\")+ (\"content\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from pathlib import Path", + "from ...utils import needs_py310", + "from fastapi import FastAPI" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 33, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_request_form_models", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"data\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_request_forms", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"data\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_request_forms_and_files", + "method_count": 8, + "imports": [ + "import importlib", + "import pytest", + "from fastapi import FastAPI", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_response_directly", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"expected_content\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_response_model", + "method_count": 35, + "algorithm": "CRX", + "grammar": "root ::= \"pytest\"? \"raises\"?+ \"FastAPIError\"? (\"TestClient\" | \"app\" | \"client\" | \"follow_redirects\" | \"get\" | \"import_module\" | \"importlib\" | \"item_data\" | \"json\" | \"mod\" | \"param\" | \"params\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\" | \"url\" | \"user_data\")+ (\"data\" | \"headers\" | \"module_name\" | \"snapshot\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310", + "from docs_src.response_model.tutorial003_02_py310 import app", + "from docs_src.response_model.tutorial003_03_py310 import app", + "from fastapi.exceptions import FastAPIError" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_response_status_code", + "method_count": 3, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_schema_extra_example", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"put\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_security", + "method_count": 73, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"access_token\" | \"app\" | \"auth\" | \"client\" | \"content\" | \"data\" | \"get\" | \"get_access_token\" | \"get_password_hash\" | \"headers\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"password\" | \"post\" | \"request\" | \"response\" | \"return\" | \"scope\" | \"status_code\" | \"text\" | \"username\" | \"verify_password\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310", + "from types import ModuleType", + "from unittest.mock import patch", + "from functools import lru_cache", + "from typing import Any, cast", + "from base64 import b64encode" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 102, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 102, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 21, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "b64encode": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "get_access_token": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 4, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "kwarg" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 4, + "types": [ + "kwarg", + "kwarg", + "kwarg", + "kwarg" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "kwarg", + "kwarg", + "kwarg" + ] + } + ] + }, + "cast": { + "occurrences": 3, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 3, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "lru_cache": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "hasattr": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_separate_openapi_schemas", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"import_module\" | \"importlib\" | \"json\" | \"mod\" | \"param\" | \"post\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_server_sent_events", + "method_count": 17, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"all\" | \"app\" | \"client\" | \"data_lines\" | \"event_lines\" | \"for\" | \"get\" | \"headers\" | \"id_lines\" | \"if\" | \"import_module\" | \"importlib\" | \"in\" | \"json\" | \"len\" | \"line\" | \"lines\" | \"mod\" | \"param\" | \"path\" | \"post\" | \"request\" | \"response\" | \"retry_lines\" | \"return\" | \"split\" | \"startswith\" | \"status_code\" | \"strip\" | \"text\")+ \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "len": { + "occurrences": 32, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 32, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "all": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 8, + "args": 2, + "types": [ + "expr", + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_settings", + "method_count": 16, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"ValidationError\" | \"admin_email\" | \"app\" | \"app_name\" | \"client\" | \"data\" | \"del\" | \"delenv\" | \"exc_info\" | \"get\" | \"get_settings\" | \"if\" | \"import_module\" | \"importlib\" | \"in\" | \"json\" | \"main_mod\" | \"mod\" | \"mod_name\" | \"mod_path\" | \"modules\" | \"monkeypatch\" | \"param\" | \"pytest\" | \"raises\" | \"raising\" | \"request\" | \"response\" | \"return\" | \"setenv\" | \"settings\" | \"status_code\" | \"sys\" | \"test_main_mod\" | \"text\")+ \"value\"? (\"items_per_user\" | \"snapshot\" | \"test_app\")?+ \"errors\"?+ \"IsAnyStr\"?", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import sys", + "import pytest", + "from dirty_equals import IsAnyStr", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from pydantic import ValidationError", + "from pytest import MonkeyPatch", + "from types import ModuleType" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_sql_databases", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"Any\" | \"StaticPool\" | \"TestClient\" | \"app\" | \"c\" | \"cast\" | \"catch_warnings\" | \"clear_sqlmodel\" | \"connect_args\" | \"create_engine\" | \"engine\" | \"import_module\" | \"importlib\" | \"mod\" | \"mod_any\" | \"param\" | \"poolclass\" | \"record\" | \"reload\" | \"request\" | \"simplefilter\" | \"sqlite_url\" | \"warnings\" | \"yield\")?+ \"SQLModel\"? (\"Is\" | \"IsInt\" | \"client\" | \"delete\" | \"get\" | \"hero_id\" | \"json\" | \"patch\" | \"post\" | \"response\" | \"snapshot\" | \"status_code\" | \"text\")?+ \"metadata\"? \"clear\"?+ \"default_registry\"? \"dispose\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import warnings", + "from typing import Any, cast", + "import pytest", + "from dirty_equals import IsInt", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from sqlalchemy import StaticPool", + "from sqlmodel import SQLModel, create_engine", + "from sqlmodel.main import default_registry", + "from tests.utils import needs_py310", + "from inline_snapshot import Is, snapshot" + ], + "arg_patterns": { + "create_engine": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "other", + "kwarg", + "kwarg" + ] + } + ] + }, + "Is": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "snapshot": { + "occurrences": 51, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 51, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "IsInt": { + "occurrences": 30, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 30, + "args": 0, + "types": [] + } + ] + }, + "clear_sqlmodel": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "cast": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_static_files", + "method_count": 4, + "imports": [ + "import os", + "from pathlib import Path", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from tests.utils import workdir_lock", + "from docs_src.static_files.tutorial001_py310 import app" + ], + "arg_patterns": { + "Path": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_stream_data", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"content\" | \"get\" | \"headers\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"path\" | \"request\" | \"response\" | \"return\" | \"status_code\" | \"text\")+ \"json\"?+ (\"binary_image\" | \"expected_text\")? \"snapshot\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_stream_json_lines", + "method_count": 3, + "imports": [ + "import importlib", + "import json", + "import pytest", + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_strict_content_type", + "method_count": 4, + "imports": [ + "import importlib", + "import pytest", + "from fastapi.testclient import TestClient" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_sub_applications", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"get\" | \"response\" | \"status_code\" | \"text\")+ \"json\"+ \"snapshot\"?+", + "mdl_score": 19226074150, + "imports": [ + "from fastapi.testclient import TestClient", + "from inline_snapshot import snapshot", + "from docs_src.sub_applications.tutorial001_py310 import app" + ], + "arg_patterns": { + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_testing", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= (\"client\" | \"get\" | \"response\" | \"status_code\" | \"text\")?+ (\"test_create_existing_item\" | \"test_create_item\" | \"test_create_item_bad_token\" | \"test_main\" | \"test_module\" | \"test_read_item\" | \"test_read_nonexistent_item\")?+ (\"ModuleType\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"request\" | \"return\")?+ \"pytest\"? (\"test_read_main\" | \"test_websocket\")?+ \"json\"?+ \"test_read_item_bad_token\"?+ \"warns\"?+ \"snapshot\"?+ \"DeprecationWarning\"?+ \"from\"? \"docs_src\"?+ \"app_testing\"?+ \"tutorial003_py310\"?+ \"import\"? \"test_read_items\"?+", + "mdl_score": 1000000000000, + "imports": [ + "from inline_snapshot import snapshot", + "from docs_src.app_testing.app_a_py310.test_main import client, test_read_main", + "import importlib", + "from types import ModuleType", + "import pytest", + "from ...utils import needs_py310", + "from docs_src.app_testing.tutorial001_py310 import client, test_read_main", + "from docs_src.app_testing.tutorial002_py310 import test_read_main, test_websocket", + "from docs_src.app_testing.tutorial003_py310 import test_read_items", + "from docs_src.app_testing.tutorial004_py310 import test_read_items" + ], + "arg_patterns": { + "test_read_main": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "snapshot": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "test_read_items": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "test_websocket": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_testing_dependencies", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"app\" | \"client\" | \"dependency_overrides\" | \"get\" | \"response\" | \"status_code\" | \"test_module\" | \"test_override_in_items\" | \"test_override_in_items_with_params\" | \"test_override_in_items_with_q\" | \"text\")?+ (\"ModuleType\" | \"import_module\" | \"importlib\" | \"mod\" | \"param\" | \"request\" | \"return\")?+ \"json\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import importlib", + "from types import ModuleType", + "import pytest", + "from ...utils import needs_py310" + ], + "arg_patterns": { + "test_override_in_items_with_params": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "test_override_in_items": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "test_override_in_items_with_q": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "tests/test_tutorial/test_websockets", + "method_count": 14, + "imports": [ + "import pytest", + "from fastapi.testclient import TestClient", + "from fastapi.websockets import WebSocketDisconnect", + "from docs_src.websockets_.tutorial001_py310 import app", + "import importlib", + "from fastapi import FastAPI", + "from ...utils import needs_py310", + "import time", + "from types import ModuleType" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "kwarg" + ] + } + ] + } + } + }, + { + "label": "tests/test_validate_response_recursive", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"TestClient\" | \"app\" | \"client\" | \"get\" | \"json\" | \"response\" | \"status_code\" | \"text\")?+ \"return\"?", + "mdl_score": 1000000000000, + "imports": [ + "from fastapi import FastAPI", + "from pydantic import BaseModel", + "from fastapi.testclient import TestClient", + "from .app import app" + ], + "arg_patterns": { + "TestClient": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "FastAPI": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "RecursiveItem": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RecursiveSubitemInSubmodel": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "RecursiveItemViaSubmodel": { + "occurrences": 1, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "class": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + } + ], + "total_methods": 4811 + } +] diff --git a/experiments/results/round20_ast_verify/ragsak.log b/experiments/results/round20_ast_verify/ragsak.log new file mode 100644 index 0000000..262b67f --- /dev/null +++ b/experiments/results/round20_ast_verify/ragsak.log @@ -0,0 +1,264 @@ +[ 0.0s] Scanning /home/tobi/Desktop/kesai/RAGSAK ... +[ 0.1s] Preprocessing 462 files across 12 workers ... +[ 2.9s] Preprocess: 1609 methods from 462 .kt files (2.8s) +[ 2.9s] Groups: 120 named, 6 ungrouped methods +[ 2.9s] ├ agents (5 methods) +[ 2.9s] ├ agents/capability/ports/src/main/kotlin/eu/corentic/springrag/agent/capability (5 methods) +[ 2.9s] ├ agents/capability/support/src/main/kotlin/eu/corentic/springrag/agent/capability/support (5 methods) +[ 2.9s] ├ agents/capability/support/src/test/kotlin/eu/corentic/springrag/agent/capability/support (6 methods) +[ 2.9s] ├ agents/examples/simple-rag/src/main/kotlin/eu/corentic/springrag/example/rag/simple (9 methods) +[ 2.9s] ├ agents/examples/simple-rag/src/test/kotlin/eu/corentic/springrag/example/rag/simple (14 methods) +[ 2.9s] ├ agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel (58 methods) +[ 2.9s] ├ agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel/librechat (13 methods) +[ 2.9s] ├ agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/agent/rag/embabel (36 methods) +[ 2.9s] ├ agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) +[ 2.9s] ├ agents/rag/ports/src/main/kotlin/eu/corentic/springrag/agent/rag (4 methods) +[ 2.9s] ├ agents/rag/ports/src/test/kotlin/eu/corentic/springrag/agent/rag (3 methods) +[ 2.9s] ├ agents/rag/ports/src/test/kotlin/eu/corentic/springrag/model (3 methods) +[ 2.9s] ├ agents/rag/support/src/main/kotlin/eu/corentic/springrag/agent/rag/support (13 methods) +[ 2.9s] ├ agents/rag/support/src/test/kotlin/eu/corentic/springrag/agent/rag/support (11 methods) +[ 2.9s] ├ agents/summarizer/embabel/src/main/kotlin/eu/corentic/springrag/agent/summarizer/embabel (13 methods) +[ 2.9s] ├ agents/summarizer/embabel/src/test/kotlin/eu/corentic/springrag/agent/summarizer/embabel (14 methods) +[ 2.9s] ├ agents/tooling/agent/src/main/kotlin/eu/corentic/springrag/agent/tooling/agent (4 methods) +[ 2.9s] ├ agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel (12 methods) +[ 2.9s] ├ agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel/recording (11 methods) +[ 2.9s] ├ agents/tooling/embabel/src/test/kotlin/eu/corentic/springrag/agent/tooling/embabel (6 methods) +[ 2.9s] ├ agents/wikipedia/adapters/src/main/kotlin/eu/corentic/springrag/agent/wikipedia (4 methods) +[ 2.9s] ├ agents/wikipedia/adapters/src/test/kotlin/eu/corentic/springrag/agent/wikipedia (8 methods) +[ 2.9s] ├ agents/wikipedia/static/src/main/kotlin/eu/corentic/springrag/agent/wikipedia (3 methods) +[ 2.9s] ├ agents/wikipedia/static/src/test/kotlin/eu/corentic/springrag/agent/wikipedia (3 methods) +[ 2.9s] ├ app/src (6 methods) +[ 2.9s] ├ app/src/e2eTest/kotlin/eu/corentic/springrag/e2e/cucumber/steps (17 methods) +[ 2.9s] ├ app/src/integrationTest/kotlin/eu/corentic/springrag/config (15 methods) +[ 2.9s] ├ app/src/integrationTest/kotlin/eu/corentic/springrag/controller (5 methods) +[ 2.9s] ├ app/src/integrationTest/kotlin/eu/corentic/springrag/service (3 methods) +[ 2.9s] ├ app/src/systemTest/kotlin/eu/corentic/springrag/config (14 methods) +[ 2.9s] ├ app/src/systemTest/kotlin/eu/corentic/springrag/system (46 methods) +[ 2.9s] ├ app/src/test/kotlin/eu/corentic/springrag/architecture (87 methods) +[ 2.9s] ├ app/src/test/kotlin/eu/corentic/springrag/config (3 methods) +[ 2.9s] ├ buildSrc/src/main/kotlin (8 methods) +[ 2.9s] ├ buildSrc/src/test/kotlin (5 methods) +[ 2.9s] ├ entrypoints/agent-mcp-server/src/main/kotlin/eu/corentic/springrag/mcp (3 methods) +[ 2.9s] ├ entrypoints/agent-mcp-server/src/test/kotlin/eu/corentic/springrag/mcp (3 methods) +[ 2.9s] ├ entrypoints/web/src/main/kotlin/eu/corentic/springrag/config (3 methods) +[ 2.9s] ├ entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller (58 methods) +[ 2.9s] ├ entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/librechat (29 methods) +[ 2.9s] ├ entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/web (6 methods) +[ 2.9s] ├ entrypoints/web/src/test/kotlin/eu/corentic/springrag/config (4 methods) +[ 2.9s] ├ entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller (83 methods) +[ 2.9s] ├ entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/auth (5 methods) +[ 2.9s] ├ entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/librechat (46 methods) +[ 2.9s] ├ entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/web (10 methods) +[ 2.9s] ├ infrastructure/adapters (3 methods) +[ 2.9s] ├ infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/config (4 methods) +[ 2.9s] ├ infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/health (3 methods) +[ 2.9s] ├ infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/config (6 methods) +[ 2.9s] ├ infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/health (4 methods) +[ 2.9s] ├ infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/service/embedding (5 methods) +[ 2.9s] ├ infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) +[ 2.9s] ├ infrastructure/adapters/chat-memory/src/test/kotlin/eu/corentic/springrag/config (6 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src (6 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/config (3 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/service/docling (21 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/systemTest/kotlin/eu/corentic/springrag/config (6 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/config (12 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/health (3 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/service/docling (10 methods) +[ 2.9s] ├ infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/health (7 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/model/graph (9 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/repository (24 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/agent (3 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/cleanup (4 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/graph (12 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/port/adapter (45 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/storage (40 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/config (4 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/repository/graph (23 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/system (6 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/config (3 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/health (6 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/model/graph (7 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/repository (19 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/cleanup (4 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/graph (30 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/port/adapter (28 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/storage (3 methods) +[ 2.9s] ├ infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) +[ 2.9s] ├ modules/chat/src/integrationTest/kotlin/eu/corentic/springrag/service/chat (4 methods) +[ 2.9s] ├ modules/chat/src/main/kotlin/eu/corentic/springrag/service/chat (6 methods) +[ 2.9s] ├ modules/chat/src/systemTest/kotlin/eu/corentic/springrag/config (15 methods) +[ 2.9s] ├ modules/chat/src/systemTest/kotlin/eu/corentic/springrag/system (4 methods) +[ 2.9s] ├ modules/chat/src/test/kotlin/eu/corentic/springrag/service/chat (8 methods) +[ 2.9s] ├ modules/common/src/main/kotlin/eu/corentic/springrag/common (7 methods) +[ 2.9s] ├ modules/common/src/main/kotlin/eu/corentic/springrag/common/ids (18 methods) +[ 2.9s] ├ modules/common/src/test/kotlin/eu/corentic/springrag/common/ids (8 methods) +[ 2.9s] ├ modules/ingestion/src/integrationTest/kotlin/eu/corentic/springrag/service/job (34 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch (16 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/listener (16 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/model (4 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/partition (4 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/reader (4 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/writer (3 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/config (26 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/chunk (18 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/document (3 methods) +[ 2.9s] ├ modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/job (62 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch (17 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/listener (34 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/model (8 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/partition (7 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/processor (5 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/reader (12 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/writer (14 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/chunk (8 methods) +[ 2.9s] ├ modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/job (49 methods) +[ 2.9s] ├ modules/knowledgebase/ports/src/main/kotlin/eu/corentic/springrag/model (5 methods) +[ 2.9s] ├ modules/knowledgebase/src/main/kotlin/eu/corentic/springrag/service/knowledgebase (11 methods) +[ 2.9s] ├ modules/knowledgebase/src/test/kotlin/eu/corentic/springrag/service/knowledgebase (16 methods) +[ 2.9s] ├ modules/security/src/main/kotlin/eu/corentic/springrag/security/config (5 methods) +[ 2.9s] ├ modules/security/src/main/kotlin/eu/corentic/springrag/security/service (10 methods) +[ 2.9s] ├ modules/security/src/test/kotlin/eu/corentic/springrag/security/config (6 methods) +[ 2.9s] ├ modules/security/src/test/kotlin/eu/corentic/springrag/security/service (15 methods) +[ 2.9s] ├ platform/test-support/src/main/kotlin/eu/corentic/springrag/testcontainers (13 methods) +[ 2.9s] ├ platform/test-support/src/test/kotlin/eu/corentic/springrag/testcontainers (5 methods) +[ 2.9s] └ (other) (6 methods) +[ 2.9s] Inferring 120 groups across 12 workers ... +[ 3.2s] [1/120] agents/rag/ports/src/test/kotlin/eu/corentic/springrag/agent/rag (3 methods) done (0.3s) +[ 3.2s] [2/120] agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) done (0.3s) +[ 3.2s] [3/120] agents/capability/support/src/test/kotlin/eu/corentic/springrag/agent/capability/support (6 methods) done (0.3s) +[ 3.2s] [4/120] agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel/librechat (13 methods) done (0.3s) +[ 3.2s] [5/120] agents/capability/support/src/main/kotlin/eu/corentic/springrag/agent/capability/support (5 methods) done (0.3s) +[ 3.2s] [6/120] agents/capability/ports/src/main/kotlin/eu/corentic/springrag/agent/capability (5 methods) done (0.3s) +[ 3.2s] [7/120] agents/rag/ports/src/main/kotlin/eu/corentic/springrag/agent/rag (4 methods) done (0.3s) +[ 3.2s] [8/120] agents/rag/ports/src/test/kotlin/eu/corentic/springrag/model (3 methods) done (0.3s) +[ 3.3s] [9/120] agents/examples/simple-rag/src/main/kotlin/eu/corentic/springrag/example/rag/simple (9 methods) done (0.3s) +[ 3.3s] [10/120] agents/tooling/agent/src/main/kotlin/eu/corentic/springrag/agent/tooling/agent (4 methods) done (0.4s) +[ 3.3s] [11/120] agents (5 methods) done (0.4s) +[ 3.3s] [12/120] agents/examples/simple-rag/src/test/kotlin/eu/corentic/springrag/example/rag/simple (14 methods) done (0.4s) +[ 3.4s] [13/120] agents/rag/support/src/main/kotlin/eu/corentic/springrag/agent/rag/support (13 methods) done (0.4s) +[ 3.4s] [14/120] agents/wikipedia/static/src/main/kotlin/eu/corentic/springrag/agent/wikipedia (3 methods) done (0.5s) +[ 3.4s] [15/120] agents/wikipedia/adapters/src/main/kotlin/eu/corentic/springrag/agent/wikipedia (4 methods) done (0.5s) +[ 3.4s] [16/120] agents/wikipedia/static/src/test/kotlin/eu/corentic/springrag/agent/wikipedia (3 methods) done (0.5s) +[ 3.4s] [17/120] agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel/recording (11 methods) done (0.5s) +[ 3.5s] [18/120] agents/tooling/embabel/src/test/kotlin/eu/corentic/springrag/agent/tooling/embabel (6 methods) done (0.6s) +[ 3.5s] [19/120] agents/wikipedia/adapters/src/test/kotlin/eu/corentic/springrag/agent/wikipedia (8 methods) done (0.6s) +[ 3.5s] [20/120] agents/rag/support/src/test/kotlin/eu/corentic/springrag/agent/rag/support (11 methods) done (0.6s) +[ 3.5s] [21/120] agents/summarizer/embabel/src/main/kotlin/eu/corentic/springrag/agent/summarizer/embabel (13 methods) done (0.6s) +[ 3.5s] [22/120] app/src/integrationTest/kotlin/eu/corentic/springrag/service (3 methods) done (0.6s) +[ 3.6s] [23/120] agents/summarizer/embabel/src/test/kotlin/eu/corentic/springrag/agent/summarizer/embabel (14 methods) done (0.7s) +[ 3.6s] [24/120] app/src/test/kotlin/eu/corentic/springrag/config (3 methods) done (0.7s) +[ 3.6s] [25/120] agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel (12 methods) done (0.7s) +[ 3.6s] [26/120] buildSrc/src/main/kotlin (8 methods) done (0.7s) +[ 3.6s] [27/120] app/src/integrationTest/kotlin/eu/corentic/springrag/controller (5 methods) done (0.7s) +[ 3.6s] [28/120] app/src/systemTest/kotlin/eu/corentic/springrag/config (14 methods) done (0.7s) +[ 3.6s] [29/120] app/src/integrationTest/kotlin/eu/corentic/springrag/config (15 methods) done (0.7s) +[ 3.7s] [30/120] buildSrc/src/test/kotlin (5 methods) done (0.8s) +[ 3.7s] [31/120] app/src (6 methods) done (0.8s) +[ 3.7s] [32/120] app/src/test/kotlin/eu/corentic/springrag/architecture (87 methods) done (0.8s) +[ 3.8s] [33/120] entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/web (6 methods) done (0.9s) +[ 3.8s] [34/120] entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/librechat (29 methods) done (0.9s) +[ 3.8s] [35/120] entrypoints/agent-mcp-server/src/test/kotlin/eu/corentic/springrag/mcp (3 methods) done (0.9s) +[ 3.8s] [36/120] entrypoints/web/src/test/kotlin/eu/corentic/springrag/config (4 methods) done (0.9s) +[ 3.8s] [37/120] entrypoints/agent-mcp-server/src/main/kotlin/eu/corentic/springrag/mcp (3 methods) done (0.9s) +[ 3.9s] [38/120] entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/auth (5 methods) done (1.0s) +[ 3.9s] [39/120] entrypoints/web/src/main/kotlin/eu/corentic/springrag/config (3 methods) done (1.0s) +[ 3.9s] [40/120] app/src/e2eTest/kotlin/eu/corentic/springrag/e2e/cucumber/steps (17 methods) done (1.0s) +[ 3.9s] [41/120] entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/web (10 methods) done (1.0s) +[ 3.9s] [42/120] infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/health (3 methods) done (1.0s) +[ 4.0s] [43/120] infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/service/embedding (5 methods) done (1.1s) +[ 4.0s] [44/120] infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/health (4 methods) done (1.1s) +[ 4.0s] [45/120] infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) done (1.1s) +[ 4.0s] [46/120] infrastructure/adapters (3 methods) done (1.1s) +[ 4.0s] [47/120] infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/config (6 methods) done (1.1s) +[ 4.0s] [48/120] infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/config (4 methods) done (1.1s) +[ 4.0s] [49/120] infrastructure/adapters/chat-memory/src/test/kotlin/eu/corentic/springrag/config (6 methods) done (1.1s) +[ 4.1s] [50/120] infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/health (3 methods) done (1.2s) +[ 4.1s] [51/120] infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/config (3 methods) done (1.2s) +[ 4.2s] [52/120] infrastructure/adapters/doc-parser/src/systemTest/kotlin/eu/corentic/springrag/config (6 methods) done (1.2s) +[ 4.2s] [53/120] infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) done (1.3s) +[ 4.2s] [54/120] infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/service/docling (10 methods) done (1.3s) +[ 4.2s] [55/120] infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/service/docling (21 methods) done (1.3s) +[ 4.2s] [56/120] infrastructure/adapters/doc-parser/src (6 methods) done (1.3s) +[ 4.3s] [57/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/health (7 methods) done (1.4s) +[ 4.3s] [58/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/agent (3 methods) done (1.4s) +[ 4.4s] [59/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/graph (12 methods) done (1.5s) +[ 4.4s] [60/120] entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller (83 methods) done (1.5s) +[ 4.4s] [61/120] entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller (58 methods) done (1.5s) +[ 4.4s] [62/120] infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/config (12 methods) done (1.5s) +[ 4.5s] [63/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/repository (24 methods) done (1.5s) +[ 4.5s] [64/120] entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/librechat (46 methods) done (1.6s) +[ 4.5s] [65/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/cleanup (4 methods) done (1.6s) +[ 4.5s] [66/120] infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/config (4 methods) done (1.6s) +[ 4.5s] [67/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/model/graph (9 methods) done (1.6s) +[ 4.5s] [68/120] agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel (58 methods) done (1.6s) +[ 4.5s] [69/120] infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/system (6 methods) done (1.6s) +[ 4.5s] [70/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/repository (19 methods) done (1.6s) +[ 4.6s] [71/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/config (3 methods) done (1.7s) +[ 4.6s] [72/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/storage (3 methods) done (1.7s) +[ 4.6s] [73/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/health (6 methods) done (1.7s) +[ 4.6s] [74/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/testsupport (3 methods) done (1.7s) +[ 4.7s] [75/120] infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/repository/graph (23 methods) done (1.8s) +[ 4.7s] [76/120] modules/chat/src/main/kotlin/eu/corentic/springrag/service/chat (6 methods) done (1.8s) +[ 4.7s] [77/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/model/graph (7 methods) done (1.8s) +[ 4.7s] [78/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/cleanup (4 methods) done (1.8s) +[ 4.8s] [79/120] modules/chat/src/systemTest/kotlin/eu/corentic/springrag/system (4 methods) done (1.8s) +[ 4.8s] [80/120] modules/chat/src/integrationTest/kotlin/eu/corentic/springrag/service/chat (4 methods) done (1.8s) +[ 4.8s] [81/120] modules/common/src/main/kotlin/eu/corentic/springrag/common (7 methods) done (1.9s) +[ 4.8s] [82/120] modules/common/src/test/kotlin/eu/corentic/springrag/common/ids (8 methods) done (1.9s) +[ 4.8s] [83/120] modules/common/src/main/kotlin/eu/corentic/springrag/common/ids (18 methods) done (1.9s) +[ 4.8s] [84/120] modules/chat/src/test/kotlin/eu/corentic/springrag/service/chat (8 methods) done (1.9s) +[ 4.9s] [85/120] modules/chat/src/systemTest/kotlin/eu/corentic/springrag/config (15 methods) done (2.0s) +[ 4.9s] [86/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch (16 methods) done (2.0s) +[ 4.9s] [87/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/storage (40 methods) done (2.0s) +[ 4.9s] [88/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/partition (4 methods) done (2.0s) +[ 4.9s] [89/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/reader (4 methods) done (2.0s) +[ 5.0s] [90/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/model (4 methods) done (2.0s) +[ 5.0s] [91/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/document (3 methods) done (2.1s) +[ 5.0s] [92/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/port/adapter (28 methods) done (2.1s) +[ 5.0s] [93/120] infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/port/adapter (45 methods) done (2.1s) +[ 5.0s] [94/120] infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/graph (30 methods) done (2.1s) +[ 5.1s] [95/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/writer (3 methods) done (2.2s) +[ 5.1s] [96/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/config (26 methods) done (2.2s) +[ 5.1s] [97/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/listener (16 methods) done (2.2s) +[ 5.1s] [98/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/partition (7 methods) done (2.2s) +[ 5.1s] [99/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/processor (5 methods) done (2.2s) +[ 5.2s] [100/120] modules/ingestion/src/integrationTest/kotlin/eu/corentic/springrag/service/job (34 methods) done (2.3s) +[ 5.2s] [101/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/model (8 methods) done (2.3s) +[ 5.2s] [102/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/reader (12 methods) done (2.3s) +[ 5.2s] [103/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/chunk (8 methods) done (2.3s) +[ 5.2s] [104/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch (17 methods) done (2.3s) +[ 5.2s] [105/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/chunk (18 methods) done (2.3s) +[ 5.3s] [106/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/writer (14 methods) done (2.4s) +[ 5.3s] [107/120] modules/knowledgebase/ports/src/main/kotlin/eu/corentic/springrag/model (5 methods) done (2.4s) +[ 5.3s] [108/120] modules/knowledgebase/src/main/kotlin/eu/corentic/springrag/service/knowledgebase (11 methods) done (2.4s) +[ 5.4s] [109/120] app/src/systemTest/kotlin/eu/corentic/springrag/system (46 methods) done (2.5s) +[ 5.4s] [110/120] modules/knowledgebase/src/test/kotlin/eu/corentic/springrag/service/knowledgebase (16 methods) done (2.5s) +[ 5.4s] [111/120] modules/security/src/main/kotlin/eu/corentic/springrag/security/config (5 methods) done (2.5s) +[ 5.4s] [112/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/listener (34 methods) done (2.5s) +[ 5.4s] [113/120] modules/security/src/main/kotlin/eu/corentic/springrag/security/service (10 methods) done (2.5s) +[ 5.4s] [114/120] modules/security/src/test/kotlin/eu/corentic/springrag/security/config (6 methods) done (2.5s) +[ 5.4s] [115/120] platform/test-support/src/test/kotlin/eu/corentic/springrag/testcontainers (5 methods) done (2.5s) +[ 5.5s] [116/120] modules/security/src/test/kotlin/eu/corentic/springrag/security/service (15 methods) done (2.5s) +[ 5.5s] [117/120] platform/test-support/src/main/kotlin/eu/corentic/springrag/testcontainers (13 methods) done (2.6s) +[ 5.8s] [118/120] modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/job (49 methods) done (2.9s) +[ 5.8s] [119/120] agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/agent/rag/embabel (36 methods) done (2.9s) +[ 5.8s] [120/120] modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/job (62 methods) done (2.9s) +[ 5.8s] Preprocessing 17 files across 12 workers ... +[ 6.1s] Preprocess: 89 methods from 17 .js files (0.3s) +[ 6.1s] Groups: 3 named, 1 ungrouped methods +[ 6.1s] ├ compose/patches (17 methods) +[ 6.1s] ├ testing/steps (68 methods) +[ 6.1s] ├ testing/support (3 methods) +[ 6.1s] └ (other) (1 methods) +[ 6.1s] Inferring 3 groups across 12 workers ... +[ 6.2s] [1/3] compose/patches (17 methods) done (0.1s) +[ 6.3s] [2/3] testing/support (3 methods) done (0.2s) +[ 6.4s] [3/3] testing/steps (68 methods) done (0.3s) +[ 6.4s] Preprocessing 5 files across 12 workers ... +[ 6.5s] Preprocessing 1 files across 12 workers ... +[ 6.6s] Preprocess: 44 methods from 1 .go files (0.1s) +[ 6.6s] Groups: 1 named, 0 ungrouped methods +[ 6.6s] ├ tools/setup-ui (44 methods) +[ 6.6s] Inferring 1 groups across 12 workers ... +[ 6.7s] [1/1] tools/setup-ui (44 methods) done (0.1s) diff --git a/experiments/results/round20_ast_verify/ragsak_golden.json b/experiments/results/round20_ast_verify/ragsak_golden.json new file mode 100644 index 0000000..254a1b7 --- /dev/null +++ b/experiments/results/round20_ast_verify/ragsak_golden.json @@ -0,0 +1,4338 @@ +[ + { + "language": ".kt", + "conventions": [ + { + "label": "agents", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"slot\"? (\"defaultCapabilityId\" | \"summarize\")? \"ToolInvocationRequest\"? \"ToolingRequest\"? \"ToolInvocationResult\"? (\"String\" | \"answer\" | \"any\" | \"assertEquals\" | \"capture\" | \"captured\" | \"every\" | \"generateText\" | \"invoke\" | \"invokeTools\" | \"promptRunner\" | \"toolProfile\" | \"verify\")?+ \"prompt\"? \"contains\"?+", + "mdl_score": 142012, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationGateway", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.PromptRunner", + "import eu.corentic.springrag.agent.tooling.embabel.DEFAULT_TOOL_PROFILE", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationAction", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationRequest", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationResult", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "agents/capability/ports/src/main/kotlin/eu/corentic/springrag/agent/capability", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"DescribedAgentCapability\"? \"AgentExecutionContext\"? \"listCapabilities\"? \"TransportExposedAgentCapability\"? \"firstOrNull\"?+ \"return AgentCapabilityDescriptor(\n id = id,\n capabilityType = capabilityType,\n displayName = describedCapability?.displayName ?: id,\n description = describedCapability?.description,\n exposedOverHttp = exposedCapability?.exposedOverHttp ?: false,\n exposedOverMcp = exposedCapability?.exposedOverMcp ?: false\n )\"? \"id\"? \"AgentCapabilityDescriptor\"? \"displayName\"? \"description\"? \"exposedOverHttp\"? \"exposedOverMcp\"?", + "mdl_score": 1553, + "imports": [], + "arg_patterns": {} + }, + { + "label": "agents/capability/support/src/main/kotlin/eu/corentic/springrag/agent/capability/support", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"resolve\"?+ \"flatMap\"?+ \"newVirtualThreadPerTaskExecutor\"?+ (\"DefaultAgentCapabilityDirectory\" | \"defaultCapabilityId\")?+ \"capabilityIdSelector\"? \"capabilityDescriptors\"?+ \"asCoroutineDispatcher\"?+ \"authorize\"?+ \"distinctBy\"?+ (\"AgentCapabilityDescriptor\" | \"capabilityType\" | \"compareBy\" | \"id\" | \"sortedWith\" | \"thenBy\")?+ \"return capability.invoke(request)\"? \"invoke\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.AgentCapabilityRegistry", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.asCoroutineDispatcher", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import java.util.concurrent.Executors", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationAuthorizer", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationGateway", + "import eu.corentic.springrag.agent.capability.AgentCapabilityResolver" + ], + "arg_patterns": {} + }, + { + "label": "agents/capability/support/src/test/kotlin/eu/corentic/springrag/agent/capability/support", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? \"TestRequest\"? (\"AgentCapabilityDescriptor\" | \"DefaultAgentCapabilityDirectory\" | \"IllegalStateException\" | \"assertEquals\" | \"assertFailsWith\" | \"authorize\" | \"capabilityDescriptors\" | \"coEvery\" | \"coVerify\" | \"defaultCapabilityId\" | \"every\" | \"id\" | \"invoke\" | \"listOf\" | \"message\" | \"resolve\" | \"verify\")?+ (\"any\" | \"listCapabilities\")?+", + "mdl_score": 790670, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityRegistry", + "import io.mockk.every", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationAuthorizer", + "import eu.corentic.springrag.agent.capability.AgentCapabilityResolver", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.verify", + "import kotlinx.coroutines.test.runTest", + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFailsWith" + ], + "arg_patterns": {} + }, + { + "label": "agents/examples/simple-rag/src/main/kotlin/eu/corentic/springrag/example/rag/simple", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= \"prompt\"?+ \"if\"? \"system\"?+ \"isEmpty\"?+ \"user\"?+ \"call\"?+ \"content\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.model.VectorChunk", + "import org.slf4j.LoggerFactory", + "import org.springframework.ai.chat.client.ChatClient", + "import tools.jackson.databind.ObjectMapper", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.support.RagDocumentSupport", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.withContext", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/examples/simple-rag/src/test/kotlin/eu/corentic/springrag/example/rag/simple", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? (\"ChatClientRequestSpec\" | \"mockk\")?+ \"CallResponseSpec\"? (\"String\" | \"any\" | \"call\" | \"every\" | \"prompt\" | \"system\" | \"user\")?+ \"content\"?+", + "mdl_score": 3710, + "imports": [ + "import eu.corentic.springrag.model.VectorChunk", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.chat.client.ChatClient", + "import org.springframework.ai.chat.client.ChatClient.CallResponseSpec", + "import org.springframework.ai.chat.client.ChatClient.ChatClientRequestSpec", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.verify", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import io.mockk.clearAllMocks", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import tools.jackson.databind.json.JsonMapper", + "import tools.jackson.module.kotlin.KotlinModule" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel", + "method_count": 58, + "imports": [ + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.resultOfType", + "import com.embabel.agent.core.Identities", + "import com.embabel.agent.core.ProcessOptions", + "import com.embabel.agent.core.support.InMemoryBlackboard", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.model.ChatResponse", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.withContext", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.stereotype.Component", + "import org.springframework.stereotype.Service", + "import kotlin.math.max", + "import eu.corentic.springrag.agent.rag.support.RagDocumentSupport", + "import eu.corentic.springrag.model.Source", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.ai.chat.memory.ChatMemory", + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.annotation.Condition", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.domain.io.UserInput", + "import eu.corentic.springrag.agent.summarizer.SummarizeRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseQueryPort", + "import io.micrometer.common.KeyValue", + "import io.micrometer.common.KeyValues", + "import org.springframework.ai.chat.client.observation.ChatClientObservationContext", + "import org.springframework.ai.chat.client.observation.DefaultChatClientObservationConvention", + "import io.micrometer.observation.ObservationRegistry", + "import java.util.function.Supplier", + "import org.springframework.ai.chat.client.ChatClient", + "import org.springframework.ai.chat.model.ChatModel", + "import org.springframework.ai.chat.client.advisor.PromptChatMemoryAdvisor", + "import org.springframework.ai.chat.prompt.ChatOptions", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel/librechat", + "method_count": 13, + "imports": [ + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.annotation.Condition", + "import com.embabel.agent.api.common.ActionContext", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.agent.rag.embabel.ConversationMemoryContext", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelJudgeDecision", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagDecisionPolicy", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowObservationContext", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowObservationConvention", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowPromptService", + "import eu.corentic.springrag.agent.rag.embabel.JudgeOutcome", + "import eu.corentic.springrag.agent.rag.embabel.RagDecisionState", + "import eu.corentic.springrag.agent.rag.embabel.RetrievedEvidence", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalResult", + "import eu.corentic.springrag.agent.rag.support.RagDocumentSupport", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Service", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.Identities", + "import com.embabel.agent.core.ProcessOptions", + "import com.embabel.agent.core.resultOfType", + "import com.embabel.agent.core.support.InMemoryBlackboard", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalInvoker", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/agent/rag/embabel", + "method_count": 36, + "algorithm": "CRX", + "grammar": "root ::= \"every\"? \"listKnowledgeBases\"?+ \"RagRequest\"? \"checkKnowledgeBase\"?+ \"assertEquals\"? \"of\"?+ \"request\"? \"knowledgeBaseId\"?", + "mdl_score": 66, + "imports": [ + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.Agent", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.AgentProcess", + "import com.embabel.agent.core.ProcessOptions", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.mockkObject", + "import io.mockk.slot", + "import io.mockk.unmockkAll", + "import io.mockk.verify", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import kotlinx.coroutines.test.runTest", + "import eu.corentic.springrag.model.PageTextElement", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.springframework.ai.chat.memory.ChatMemory", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseListItem", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseQueryPort", + "import org.springframework.ai.chat.client.ChatClientRequest", + "import org.springframework.ai.chat.client.observation.ChatClientObservationContext", + "import org.springframework.ai.chat.prompt.Prompt", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import io.micrometer.observation.ObservationRegistry", + "import org.springframework.ai.chat.memory.InMemoryChatMemoryRepository", + "import org.springframework.ai.chat.memory.MessageWindowChatMemory", + "import org.springframework.ai.chat.messages.AssistantMessage", + "import org.springframework.ai.chat.messages.MessageType", + "import org.springframework.ai.chat.messages.UserMessage", + "import org.springframework.ai.chat.model.ChatModel", + "import org.springframework.ai.chat.model.ChatResponse", + "import org.springframework.ai.chat.model.Generation", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelJudgeDecision", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagDecisionPolicy", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagWorkflowAgentProperties", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowPromptService", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.service.port.VectorDocumentPort" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"Any\" | \"Builder\" | \"get\")+", + "mdl_score": 15, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/ports/src/main/kotlin/eu/corentic/springrag/agent/rag", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"defaultCapabilityId\"? \"answer\"? \"request\"? \"AgentExecutionContext\"? \"RagRequest\"? \"executionContext\"? \"let\"?+ \"KnowledgeBaseId\"?", + "mdl_score": 242, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapability", + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationGateway" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/ports/src/test/kotlin/eu/corentic/springrag/agent/rag", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? \"return ChatResponse(answer = \\\"ok\\\", sources = emptyList())\"? \"RecordingRagAgent\"? \"ChatResponse\"? \"RagInvocation\"? \"emptyList\"?+ \"RagRequest\"? \"invoke\"?+ (\"answer\" | \"asKnowledgeBaseId\" | \"assertEquals\" | \"conversationId\" | \"knowledgeBaseId\" | \"lastRequest\" | \"message\")?+ \"executionContext\"? \"agentId\"? \"lastContext\"?", + "mdl_score": 3304, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/ports/src/test/kotlin/eu/corentic/springrag/model", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"ChatResponse\"? (\"Source\" | \"emptyList\" | \"listOf\")?+ \"toMarkdownSummary\"?+ (\"assertTrue\" | \"contains\")?+", + "mdl_score": 858, + "imports": [ + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/support/src/main/kotlin/eu/corentic/springrag/agent/rag/support", + "method_count": 13, + "algorithm": "CRX", + "grammar": "root ::= (\"String\" | \"metadata\")+", + "mdl_score": 62, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.toDescriptor", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagAgentRegistry", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.Source", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/support/src/test/kotlin/eu/corentic/springrag/agent/rag/support", + "method_count": 11, + "algorithm": "CRX", + "grammar": "root ::= \"VectorChunk\"? \"mapOf\"?+ (\"every\" | \"id\")?+ \"capabilityType\"? \"DefaultRagAgentRegistry\"? \"listOf\"?+ \"assertEquals\"?", + "mdl_score": 100, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationAuthorizer", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagAgentRegistry", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.Assertions.assertDoesNotThrow", + "import eu.corentic.springrag.model.PageTextElement", + "import eu.corentic.springrag.model.SourceImage", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "agents/summarizer/embabel/src/main/kotlin/eu/corentic/springrag/agent/summarizer/embabel", + "method_count": 13, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.toDescriptor", + "import eu.corentic.springrag.agent.summarizer.SummarizerAgent", + "import eu.corentic.springrag.agent.summarizer.SummarizerAgentRegistry", + "import org.springframework.stereotype.Component", + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.Identities", + "import com.embabel.agent.core.ProcessOptions", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import eu.corentic.springrag.agent.summarizer.SummarizeRequest", + "import eu.corentic.springrag.agent.summarizer.SummaryResponse", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.Dispatchers", + "import kotlinx.coroutines.withContext", + "import org.springframework.stereotype.Service", + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.domain.io.UserInput", + "import com.embabel.common.ai.model.LlmOptions", + "import eu.corentic.springrag.agent.tooling.embabel.DEFAULT_TOOL_PROFILE", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationAction", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationRequest", + "import org.springframework.beans.factory.annotation.Value", + "import eu.corentic.springrag.agent.summarizer.SummarizerInvocationAuthorizer", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/summarizer/embabel/src/test/kotlin/eu/corentic/springrag/agent/summarizer/embabel", + "method_count": 14, + "imports": [ + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.ProcessOptions", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.summarizer.SummarizeRequest", + "import eu.corentic.springrag.agent.summarizer.SummaryResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.mockkObject", + "import io.mockk.slot", + "import io.mockk.unmockkAll", + "import io.mockk.verify", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.summarizer.SummarizerAgent", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import eu.corentic.springrag.agent.summarizer.SummarizerInvocationAuthorizer", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import kotlinx.coroutines.test.runTest", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.Ai", + "import com.embabel.agent.api.common.PromptRunner", + "import com.embabel.common.ai.model.LlmOptions", + "import org.junit.jupiter.api.Assertions.assertDoesNotThrow" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/agent/src/main/kotlin/eu/corentic/springrag/agent/tooling/agent", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= (\"buildString\" | \"forEachIndexed\" | \"if\" | \"ifBlank\" | \"isEmpty\" | \"response\" | \"return buildString {\n result.toolCalls.forEachIndexed { index, call ->\n if (index > 0) append(\\\"\\\\n\\\\n\\\")\n append(\\\"Tool: \\\").append(call.tool).append(\\\"\\\\n\\\")\n append(\\\"Input: \\\").append(call.input).append(\\\"\\\\n\\\")\n append(\\\"Output:\\\\n\\\").append(call.output)\n }\n }\" | \"return result.response.ifBlank { \\\"No tool results were captured.\\\" }\" | \"toolCalls\")?+ \"ToolingRequest\"? \"goal\"? (\"append\" | \"input\" | \"tool\")?+ \"content\"? \"renderToolResults\"? \"output\"? \"trimIndent\"?+ \"promptRunner\"?+ \"return toolInvocationAction.invoke(\n ToolInvocationRequest(\n prompt = prompt,\n toolProfile = request.toolProfile\n ),\n context\n )\"? \"LlmOptions\"? \"invoke\"?+ \"emptySet\"?+ \"ToolInvocationRequest\"? \"emptyList\"?+ \"toolProfile\"? \"generateText\"?+ \"trim\"?+ \"return ToolingResponse(answer = answer)\"? \"ToolingResponse\"?", + "mdl_score": 0, + "imports": [ + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.domain.io.UserInput", + "import com.embabel.common.ai.model.LlmOptions", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationAction", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationRequest", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationResult", + "import org.springframework.stereotype.Service" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel", + "method_count": 12, + "imports": [ + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import com.embabel.agent.api.tool.ToolObject", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.ContextualPromptElement", + "import com.embabel.common.ai.model.LlmOptions", + "import com.embabel.common.ai.prompt.PromptContributor", + "import com.embabel.agent.prompt.element.FocusedToolCallControl", + "import com.embabel.agent.prompt.element.ToolCallControl", + "import eu.corentic.springrag.agent.tooling.embabel.recording.ToolCallRecord", + "import eu.corentic.springrag.agent.tooling.embabel.recording.ToolInvocationRecorder", + "import org.springframework.stereotype.Service", + "import org.springframework.boot.context.properties.ConfigurationProperties", + "import org.springaicommunity.agent.tools.FileSystemTools", + "import org.springaicommunity.agent.tools.GrepTool", + "import org.springaicommunity.agent.tools.GlobTool", + "import org.springaicommunity.agent.tools.ShellTools", + "import org.springaicommunity.agent.tools.SmartWebFetchTool", + "import org.springframework.ai.chat.client.ChatClient", + "import org.springframework.boot.context.properties.EnableConfigurationProperties" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel/recording", + "method_count": 11, + "imports": [ + "import com.embabel.agent.api.event.AgentProcessEvent", + "import com.embabel.agent.api.event.AgenticEventListener", + "import com.embabel.agent.api.event.ToolCallResponseEvent", + "import com.fasterxml.jackson.core.JsonProcessingException", + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.slf4j.LoggerFactory", + "import java.util.concurrent.ConcurrentHashMap", + "import com.embabel.agent.api.common.PlatformServices", + "import com.embabel.agent.api.event.MulticastAgenticEventListener", + "import org.springframework.beans.factory.config.BeanPostProcessor", + "import org.springframework.boot.context.properties.EnableConfigurationProperties", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/embabel/src/test/kotlin/eu/corentic/springrag/agent/tooling/embabel", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"ToolInvocationPolicyProperties\"? (\"AgentProcess\" | \"Any\" | \"PolicyAwareToolInvocationToolProvider\" | \"StaticToolInvocationToolProvider\" | \"ToolInvocationAction\" | \"ToolInvocationRequest\" | \"ToolObject\" | \"ToolProfilePolicy\" | \"addObject\" | \"agent\" | \"agentProcess\" | \"any\" | \"assertEquals\" | \"assertFalse\" | \"assertTrue\" | \"blackboard\" | \"capture\" | \"com\" | \"core\" | \"embabel\" | \"every\" | \"filter\" | \"generateText\" | \"get\" | \"id\" | \"invoke\" | \"listOf\" | \"mapOf\" | \"mockk\" | \"processContext\" | \"promptRunner\" | \"response\" | \"set\" | \"setOf\" | \"single\" | \"slot\" | \"toolObjectsFor\" | \"toolProfile\" | \"verify\" | \"withToolChainingFromAny\")?+ (\"captured\" | \"emptyList\")?+", + "mdl_score": 16597680, + "imports": [ + "import com.embabel.agent.api.tool.ToolObject", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.PromptRunner", + "import com.embabel.agent.core.Blackboard", + "import com.embabel.agent.core.ProcessContext", + "import io.mockk.Runs", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/adapters/src/main/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"values\"? \"when\"? \"debug\"?+ \"sortedBy\"?+ \"isNullOrBlank\"?+ \"topic\"? \"id\"? \"else\"? \"map\"?+ \"error\"?+ \"toDescriptor\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.toDescriptor", + "import org.springframework.stereotype.Component", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/adapters/src/test/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"every\" | \"id\")?+ \"defaultCapabilityId\"?+ \"capabilityType\"? \"DefaultWikipediaLookupAgentRegistry\"? (\"assertEquals\" | \"listOf\")?+ \"AgentCapabilityDescriptor\"? \"capabilityDescriptors\"?+", + "mdl_score": 32, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import io.mockk.every", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.Test", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.verify", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertDoesNotThrow" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/static/src/main/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"WikipediaLookupResponse\" | \"contains\" | \"firstOrNull\" | \"normalize\" | \"return keywordMatch ?: WikipediaLookupResponse(\n topic = request.topic,\n summary = \\\"No static encyclopedia entry was found for \\\\\\\"${request.topic}\\\\\\\". This static capability can later be replaced with a real Wikipedia or MCP-backed lookup agent.\\\",\n wikipediaUrl = null,\n found = false\n )\" | \"topic\")?+ \"trim\"?+ \"lowercase\"?+ \"replace\"?+ \"Regex\"?", + "mdl_score": 120, + "imports": [ + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/static/src/test/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? \"invoke\"?+ \"WikipediaLookupRequest\"? \"assertFalse\"? (\"assertEquals\" | \"assertTrue\" | \"contains\" | \"found\" | \"summary\" | \"topic\")?+ \"wikipediaUrl\"?", + "mdl_score": 8136, + "imports": [ + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "app/src", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= (\"assertTrue\" | \"isRunning\" | \"neo4jContainer\" | \"ollamaContainer\" | \"qdrantContainer\")?+ \"YamlPropertiesFactoryBean\"? \"assertNotNull\"? \"getenv\"?+ \"activeProfiles\"? \"setResources\"?+ \"return WebTestClient.bindToServer().baseUrl(baseUrl).build()\"? \"joinToString\"?+ \"ClassPathResource\"? \"bindToServer\"?+ \"ifBlank\"?+ \"`object`\"? \"baseUrl\"?+ (\"ConfigurableEnvironment\" | \"EnumerablePropertySource\" | \"String\" | \"add\" | \"first\" | \"forEach\" | \"getProperty\" | \"if\" | \"info\" | \"linkedSetOf\" | \"map\" | \"propertyNames\" | \"propertySources\" | \"return\" | \"return if (SECRET_KEY_PATTERNS.any { it.containsMatchIn(key) }) \\\"******\\\" else value\" | \"return value\" | \"size\" | \"sortedBy\" | \"warn\")?+ \"emptyMap\"?+ \"build\"?+ \"maskValue\"? \"any\"?+ (\"assertEquals\" | \"replace\" | \"toString\")?+ \"containsMatchIn\"?+ \"else\"?", + "mdl_score": 0, + "imports": [ + "import io.cucumber.spring.CucumberContextConfiguration", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Import", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.ApplicationArguments", + "import org.springframework.boot.ApplicationRunner", + "import org.springframework.core.env.ConfigurableEnvironment", + "import org.springframework.core.env.Environment", + "import org.springframework.core.env.EnumerablePropertySource", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import kotlin.test.assertEquals", + "import org.springframework.beans.factory.config.YamlPropertiesFactoryBean", + "import org.springframework.core.io.ClassPathResource" + ], + "arg_patterns": {} + }, + { + "label": "app/src/e2eTest/kotlin/eu/corentic/springrag/e2e/cucumber/steps", + "method_count": 17, + "algorithm": "CRX", + "grammar": "root ::= \"post\"?+ \"exchange\"?+ \"uri\"?+ \"expectStatus\"?+ \"contentType\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.e2e.cucumber.config.ScenarioContext", + "import io.cucumber.java.en.Given", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.http.MediaType", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import java.util.UUID", + "import io.cucumber.java.en.Then", + "import io.cucumber.java.en.When", + "import io.cucumber.java.Before", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.web.reactive.function.BodyInserters", + "import java.io.File", + "import java.time.Duration" + ], + "arg_patterns": {} + }, + { + "label": "app/src/integrationTest/kotlin/eu/corentic/springrag/config", + "method_count": 15, + "imports": [ + "import org.springframework.batch.core.repository.JobRepository", + "import org.springframework.batch.test.JobRepositoryTestUtils", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.context.annotation.Bean", + "import ai.docling.serve.api.DoclingServeApi", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagResponseInvoker", + "import eu.corentic.springrag.agent.summarizer.embabel.EmbabelSummarizerResponseInvoker", + "import com.embabel.agent.core.AgentPlatform", + "import io.mockk.mockk", + "import io.qdrant.client.QdrantClient", + "import org.neo4j.driver.Driver", + "import org.neo4j.driver.Session", + "import org.springframework.ai.chat.model.ChatModel", + "import org.springframework.ai.chat.prompt.ChatOptions", + "import org.springframework.ai.embedding.EmbeddingModel", + "import org.springframework.ai.vectorstore.VectorStore", + "import org.springframework.context.annotation.Primary", + "import org.springframework.security.authentication.ReactiveAuthenticationManager", + "import org.springframework.batch.core.launch.JobOperator" + ], + "arg_patterns": {} + }, + { + "label": "app/src/integrationTest/kotlin/eu/corentic/springrag/controller", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= (\"Ok\" | \"ParsedJwt\" | \"SimpleGrantedAuthority\" | \"any\" | \"every\" | \"extractAuthorities\" | \"extractUsername\" | \"listOf\" | \"parseToken\" | \"validateToken\")?+ \"generateToken\"?+ \"ByteArray\"? \"get\"?+ \"bindToServer\"?+ \"User\"? \"InputStreamResource\"?+ \"baseUrl\"?+ \"ROLE_ADMIN\"? \"ByteArrayInputStream\"? \"mutate\"?+ \"fun\"? \"defaultHeader\"?+ \"Long\"?+ \"MultipartBodyBuilder\"? \"part\"?+ (\"header\" | \"post\" | \"uri\")?+ \"AUTHORIZATION\"? \"contentType\"?+ \"MULTIPART_FORM_DATA\"? \"body\"?+ \"fromMultipartData\"?+ \"build\"?+ \"exchange\"?+ \"expectStatus\"?+ \"isOk\"? \"isNotFound\"? \"expectBody\"?+ \"jsonPath\"?+ \"isEqualTo\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.config.IntegrationTestConfig", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.model.User", + "import eu.corentic.springrag.security.service.JwtService", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.BeforeEach", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.context.annotation.Import", + "import org.springframework.http.HttpHeaders", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import com.ninjasquad.springmockk.MockkBean", + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseService", + "import io.mockk.every", + "import java.io.ByteArrayInputStream", + "import org.springframework.core.io.InputStreamResource", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.MediaType", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.security.core.authority.SimpleGrantedAuthority", + "import org.springframework.web.reactive.function.BodyInserters", + "import org.springframework.boot.test.web.server.LocalServerPort" + ], + "arg_patterns": {} + }, + { + "label": "app/src/integrationTest/kotlin/eu/corentic/springrag/service", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"Instant\" | \"JobId\" | \"KnowledgeBaseId\" | \"common\" | \"corentic\" | \"ids\" | \"of\" | \"parse\" | \"randomUUID\" | \"springrag\" | \"time\")?+ \"stream\"?+ \"model\"? (\"Assertions\" | \"anyMatch\" | \"api\" | \"assertTrue\" | \"expected\" | \"java\" | \"junit\" | \"jupiter\")?+ \"KnowledgeBase\"?+ \"simpleName\"? (\"every\" | \"existsById\")?+ \"existsByJobIdAndKnowledgeBaseId\"?+ \"findById\"?+ \"deleteDocument\"?+ \"deleteKnowledgeBase\"?+ \"DocumentDeletionRequested\"? \"KnowledgeBaseDeletionRequested\"? \"assertApplicationEventPublished\"?", + "mdl_score": 0, + "imports": [ + "import com.ninjasquad.springmockk.MockkBean", + "import eu.corentic.springrag.config.IntegrationTestConfig", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import io.mockk.every", + "import java.util.UUID", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.context.annotation.Import", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.event.ApplicationEvents", + "import org.springframework.test.context.event.RecordApplicationEvents" + ], + "arg_patterns": {} + }, + { + "label": "app/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 14, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport.recreateTestCollection", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import io.qdrant.client.QdrantClient", + "import java.time.Duration", + "import java.time.Instant", + "import java.util.UUID", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.junit.jupiter.api.BeforeEach", + "import org.neo4j.driver.Driver", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.jdbc.core.JdbcTemplate", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.springframework.test.context.TestPropertySource", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.testcontainers.junit.jupiter.Testcontainers", + "import java.sql.Timestamp", + "import org.springframework.batch.core.repository.JobRepository", + "import org.springframework.batch.test.JobRepositoryTestUtils", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.context.annotation.Bean", + "import org.mockito.Mockito", + "import org.springframework.context.annotation.Primary" + ], + "arg_patterns": {} + }, + { + "label": "app/src/systemTest/kotlin/eu/corentic/springrag/system", + "method_count": 46, + "imports": [ + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.controller.SessionChatRequest", + "import eu.corentic.springrag.model.ChatResponse", + "import java.time.Duration", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.test.web.reactive.server.returnResult", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.repository.VectorRepository", + "import eu.corentic.springrag.repository.graph.DocumentJobNodeRepository", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import java.io.File", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.nio.file.StandardCopyOption", + "import kotlin.io.path.createDirectory", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions.assertNotEquals", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.core.io.ClassPathResource", + "import org.springframework.http.MediaType", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.web.reactive.function.BodyInserters", + "import io.modelcontextprotocol.client.McpClient", + "import io.modelcontextprotocol.client.McpSyncClient", + "import io.modelcontextprotocol.client.transport.WebClientStreamableHttpTransport", + "import io.modelcontextprotocol.spec.McpSchema", + "import org.springframework.boot.test.web.server.LocalServerPort", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.web.reactive.function.client.WebClient", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotEquals", + "import kotlin.test.assertTrue", + "import org.neo4j.driver.Values", + "import eu.corentic.springrag.service.job.JobService", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.assertThrows", + "import java.util.*", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import java.util.stream.Stream", + "import org.awaitility.core.ConditionTimeoutException", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.params.ParameterizedTest", + "import org.junit.jupiter.params.provider.Arguments", + "import org.junit.jupiter.params.provider.MethodSource" + ], + "arg_patterns": {} + }, + { + "label": "app/src/test/kotlin/eu/corentic/springrag/architecture", + "method_count": 87, + "imports": [ + "import java.nio.file.Files", + "import java.nio.file.Path", + "import kotlin.io.path.exists", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.fail", + "import com.lemonappdev.konsist.api.Konsist", + "import com.lemonappdev.konsist.api.ext.list.withAnnotationOf", + "import com.lemonappdev.konsist.api.verify.assertTrue", + "import org.springframework.stereotype.Service", + "import java.io.IOException", + "import java.nio.file.FileVisitResult", + "import java.nio.file.Paths", + "import java.nio.file.SimpleFileVisitor", + "import java.nio.file.attribute.BasicFileAttributes" + ], + "arg_patterns": {} + }, + { + "label": "app/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"loadYaml\"? \"YamlPropertiesFactoryBean\"? \"assertFalse\"? \"setResources\"?+ (\"assertEquals\" | \"assertTrue\" | \"containsKey\")?+ \"ClassPathResource\"? \"return factory.`object` ?: emptyMap()\"? \"`object`\"? \"emptyMap\"?+", + "mdl_score": 480, + "imports": [ + "import kotlin.test.assertEquals", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.config.YamlPropertiesFactoryBean", + "import org.springframework.core.io.ClassPathResource" + ], + "arg_patterns": {} + }, + { + "label": "buildSrc/src/main/kotlin", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"getByType\"+ \"SourceSetContainer\"?", + "mdl_score": 5, + "imports": [ + "import org.gradle.api.Project", + "import org.gradle.api.artifacts.VersionCatalogsExtension", + "import org.gradle.api.file.SourceDirectorySet", + "import org.gradle.api.plugins.JavaPluginExtension", + "import org.gradle.api.tasks.SourceSet", + "import org.gradle.api.tasks.SourceSetContainer", + "import org.gradle.api.tasks.TaskProvider", + "import org.gradle.api.tasks.testing.Test", + "import org.gradle.jvm.toolchain.JavaLanguageVersion", + "import org.gradle.kotlin.dsl.get", + "import org.gradle.kotlin.dsl.getByType", + "import org.gradle.kotlin.dsl.named", + "import org.gradle.kotlin.dsl.register", + "import org.gradle.kotlin.dsl.withType" + ], + "arg_patterns": {} + }, + { + "label": "buildSrc/src/test/kotlin", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"withType\"?+ (\"build\" | \"builder\" | \"withName\" | \"withParent\")?+ \"MavenArtifactRepository\"? \"pluginManager\"? \"configureStandardRepositories\"?+ \"apply\"?+ \"mavenRepositoryUrls\"?+ \"extensions\"? \"getByType\"?+ \"SourceSetContainer\"? \"java\"? \"create\"?+ \"registerJvmTestTask\"?+ (\"get\" | \"named\" | \"register\" | \"registerStandardAggregateVerificationTasks\" | \"tasks\")?+ (\"URI\" | \"assertEquals\" | \"assertFalse\" | \"assertNotNull\" | \"assertTrue\" | \"classesDirs\" | \"classpath\" | \"contains\" | \"description\" | \"files\" | \"getDependencies\" | \"group\" | \"map\" | \"output\" | \"path\" | \"runtimeClasspath\" | \"setOf\" | \"size\" | \"taskDependencies\" | \"testClassesDirs\" | \"toSet\" | \"url\")?+ \"isEmpty\"?+ \"filter\"? \"isFailOnNoMatchingTests\"?", + "mdl_score": 0, + "imports": [ + "import java.net.URI", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFalse", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import org.gradle.api.artifacts.repositories.MavenArtifactRepository", + "import org.gradle.api.tasks.SourceSetContainer", + "import org.gradle.testfixtures.ProjectBuilder", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/agent-mcp-server/src/main/kotlin/eu/corentic/springrag/mcp", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"mono\"? \"listCapabilities\"?+ \"filter\"?+ \"AgentCapabilityDescriptor\"? (\"KnowledgeBaseId\" | \"RagInvocation\" | \"RagRequest\" | \"WikipediaLookupRequest\" | \"addTextContent\" | \"builder\" | \"capabilityType\" | \"description\" | \"displayName\" | \"else\" | \"id\" | \"if\" | \"invoke\" | \"isEmpty\" | \"isNullOrBlank\" | \"joinToString\" | \"let\" | \"mapOf\" | \"mcp\" | \"structuredContent\" | \"summary\" | \"toMarkdownSummary\" | \"topic\" | \"wikipediaUrl\")?+ \"found\"? \"build\"?+", + "mdl_score": 1512, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.isExposedOverMcp", + "import io.modelcontextprotocol.spec.McpSchema.CallToolResult", + "import kotlinx.coroutines.reactor.mono", + "import org.springaicommunity.mcp.annotation.McpTool", + "import org.springframework.stereotype.Component", + "import reactor.core.publisher.Mono", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.toMarkdownSummary", + "import org.springaicommunity.mcp.annotation.McpToolParam", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupInvocationGateway", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupRequest" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/agent-mcp-server/src/test/kotlin/eu/corentic/springrag/mcp", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"WikipediaLookupResponse\"? \"AgentCapabilityDescriptor\"?+ \"ChatResponse\"? \"every\"? (\"Source\" | \"listCapabilities\" | \"listOf\")?+ \"coEvery\"? \"invoke\"?+ \"any\"? (\"ragAnswer\" | \"wikipediaLookup\")?+ \"block\"?+ \"content\"?+ \"first\"?+ \"TextContent\"? (\"assertTrue\" | \"contains\" | \"text\")?+ \"@\"? \"Suppress\"?+ (\"Any\" | \"List\" | \"Map\" | \"String\" | \"assertEquals\" | \"structuredContent\")?+ \"size\"?", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.modelcontextprotocol.spec.McpSchema.TextContent", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.model.Source", + "import io.mockk.coEvery", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupInvocationGateway", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupResponse" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"defer\"?+ \"addMapping\"?+ \"allowedOriginPatterns\"?+ \"split\"?+ \"map\"?+ \"trim\"?+ (\"contains\" | \"doFinally\" | \"else\" | \"filter\" | \"if\" | \"method\" | \"name\" | \"nanoTime\" | \"path\" | \"pathWithinApplication\" | \"put\" | \"request\" | \"response\" | \"return chain.filter(exchange)\" | \"return chain.filter(exchange)\n .doFinally {\n val tookMs = (System.nanoTime() - startedAt) / 1_000_000\n val status = exchange.response.statusCode?.value() ?: 0\n logger.info { \\\"LIBRECHAT $method $path -> $status (${tookMs}ms)\\\" }\n }\" | \"startsWith\" | \"statusCode\" | \"uri\" | \"value\" | \"when\")?+ \"isNotEmpty\"?+ (\"info\" | \"remove\")?+ \"toTypedArray\"?+ \"allowedMethods\"?+ \"allowedHeaders\"?+ \"allowCredentials\"?+", + "mdl_score": 0, + "imports": [ + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.web.reactive.config.CorsRegistry", + "import org.springframework.web.reactive.config.WebFluxConfigurer", + "import org.slf4j.MDC", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.web.server.ServerWebExchange", + "import org.springframework.web.server.WebFilter", + "import org.springframework.web.server.WebFilterChain", + "import reactor.core.publisher.Mono", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.core.Ordered", + "import org.springframework.core.annotation.Order", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller", + "method_count": 58, + "algorithm": "CRX", + "grammar": "root ::= \"warn\"?+ \"message\"? \"status\"?+", + "mdl_score": 14, + "imports": [ + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.job.BatchOwnershipService", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseNotFoundException", + "import jakarta.validation.constraints.NotBlank", + "import jakarta.validation.constraints.Pattern", + "import org.springframework.http.ResponseEntity", + "import org.springframework.security.access.prepost.PreAuthorize", + "import org.springframework.security.core.Authentication", + "import org.springframework.validation.annotation.Validated", + "import org.springframework.web.bind.annotation.*", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.service.chat.ChatService", + "import jakarta.validation.Valid", + "import org.springframework.web.bind.annotation.GetMapping", + "import org.springframework.web.bind.annotation.PostMapping", + "import org.springframework.web.bind.annotation.RequestBody", + "import org.springframework.web.bind.annotation.RequestMapping", + "import org.springframework.web.bind.annotation.RestController", + "import kotlinx.coroutines.TimeoutCancellationException", + "import kotlinx.coroutines.withTimeout", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.beans.factory.annotation.Value", + "import java.util.UUID", + "import eu.corentic.springrag.controller.dto.ErrorResponse", + "import eu.corentic.springrag.security.service.PasswordPolicyViolationException", + "import eu.corentic.springrag.security.service.UserAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.DocumentNotFoundInKnowledgeBaseException", + "import eu.corentic.springrag.service.knowledgebase.InvalidKnowledgeBaseNameException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseSizeLimitExceededException", + "import eu.corentic.springrag.service.job.JobAlreadyCompleteException", + "import eu.corentic.springrag.service.job.JobAlreadyRunningException", + "import eu.corentic.springrag.service.job.JobExecutionNotFoundException", + "import eu.corentic.springrag.service.job.BatchOwnershipException", + "import eu.corentic.springrag.service.job.BatchNotFoundException", + "import eu.corentic.springrag.service.job.BatchOwnerRequiredException", + "import eu.corentic.springrag.service.job.JobInputValidationException", + "import jakarta.validation.ConstraintViolationException", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.converter.HttpMessageNotReadableException", + "import org.springframework.core.io.buffer.DataBufferLimitException", + "import org.springframework.web.bind.MethodArgumentNotValidException", + "import org.springframework.web.bind.annotation.ExceptionHandler", + "import org.springframework.web.bind.annotation.RestControllerAdvice", + "import org.springframework.web.method.annotation.MethodArgumentTypeMismatchException", + "import org.springframework.web.server.ServerWebInputException", + "import org.springframework.web.server.MissingRequestValueException", + "import org.springframework.web.bind.support.WebExchangeBindException", + "import eu.corentic.springrag.service.knowledgebase.*", + "import io.swagger.v3.oas.annotations.Operation", + "import io.swagger.v3.oas.annotations.tags.Tag", + "import io.swagger.v3.oas.annotations.Parameter", + "import java.security.Principal", + "import kotlinx.coroutines.reactor.awaitSingle", + "import org.springframework.http.codec.multipart.FilePart", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import kotlinx.coroutines.reactor.awaitSingleOrNull", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import org.springframework.core.io.buffer.DataBufferUtils", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.security.service.JwtService", + "import eu.corentic.springrag.security.service.UserService", + "import org.springframework.security.crypto.password.PasswordEncoder" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/librechat", + "method_count": 29, + "imports": [ + "import com.fasterxml.jackson.annotation.JsonProperty", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.service.document.DocumentIdentity", + "import eu.corentic.springrag.service.port.DocumentIdPort", + "import eu.corentic.springrag.service.port.DocumentImagePort", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.service.port.VectorDocumentDeletionPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalInvoker", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.port.AgentKnowledgeBasePort", + "import jakarta.validation.Valid", + "import jakarta.validation.constraints.NotBlank", + "import jakarta.validation.constraints.NotEmpty", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.withContext", + "import kotlinx.coroutines.reactor.awaitSingleOrNull", + "import org.springframework.http.MediaType", + "import org.springframework.http.ResponseEntity", + "import org.springframework.http.codec.multipart.FilePart", + "import org.springframework.web.bind.annotation.*", + "import org.springframework.core.io.buffer.DataBufferUtils", + "import kotlin.math.max", + "import kotlin.math.min", + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.controller.InvalidUploadRequestException", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.util.UUID", + "import kotlin.time.Duration.Companion.seconds", + "import kotlinx.coroutines.delay", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/web", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"collectList\"?+ (\"return \\\"chat\\\"\" | \"return \\\"index\\\"\" | \"return \\\"jobs\\\"\" | \"return \\\"knowledge-bases\\\"\" | \"return \\\"upload\\\"\")? \"awaitSingle\"?+ \"try\"? \"handleUpload\"?+ \"name\"? (\"IllegalArgumentException\" | \"InvalidUploadRequestException\" | \"KnowledgeBaseNotFoundException\" | \"RuntimeException\" | \"badRequest\" | \"body\" | \"catch\" | \"internalServerError\" | \"mapOf\" | \"message\" | \"return ResponseEntity.badRequest()\n .body(mapOf(\\\"error\\\" to (e.message ?: \\\"Invalid request\\\")))\" | \"return ResponseEntity.badRequest()\n .body(mapOf(\\\"error\\\" to (e.message ?: \\\"Invalid upload request\\\")))\" | \"return ResponseEntity.badRequest()\n .body(mapOf(\\\"error\\\" to (e.message ?: \\\"Knowledge base not found\\\")))\" | \"return ResponseEntity.internalServerError()\n .body(mapOf(\\\"error\\\" to \\\"Failed to upload files: ${e.message}\\\"))\")?+ \"mutableMapOf\"?+ \"String\"?+ \"Any\"? \"batchId\"? \"fileCount\"? \"files\"? \"if\"? \"jobTriggered\"? \"jobId\"? \"jobError\"? \"let\"?+ \"return ResponseEntity.ok(response)\"? \"ok\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.controller.UploadWorkflow", + "import eu.corentic.springrag.controller.InvalidUploadRequestException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseNotFoundException", + "import java.security.Principal", + "import kotlinx.coroutines.reactor.awaitSingle", + "import org.springframework.http.MediaType", + "import org.springframework.http.ResponseEntity", + "import org.springframework.http.codec.multipart.FilePart", + "import org.springframework.stereotype.Controller", + "import org.springframework.web.bind.annotation.PostMapping", + "import org.springframework.web.bind.annotation.RequestParam", + "import org.springframework.web.bind.annotation.RequestPart", + "import org.springframework.web.bind.annotation.ResponseBody", + "import reactor.core.publisher.Flux", + "import org.springframework.web.bind.annotation.GetMapping" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"bindToWebHandler\"?+ \"from\"?+ \"webTestClient\"? \"WebHandler\"? \"post\"?+ (\"OK\" | \"response\" | \"setStatusCode\")?+ \"setComplete\"?+ \"webFilter\"?+ \"build\"?+ (\"AtomicReference\" | \"String\")?+ \"WebFilterChain\"? (\"assertEquals\" | \"assertNull\" | \"block\" | \"empty\" | \"filter\" | \"get\" | \"set\")?+ \"uri\"?+ \"exchange\"?+ \"expectStatus\"?+ \"isOk\"?", + "mdl_score": 0, + "imports": [ + "import java.util.concurrent.atomic.AtomicReference", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import org.slf4j.MDC", + "import org.springframework.mock.http.server.reactive.MockServerHttpRequest", + "import org.springframework.mock.web.server.MockServerWebExchange", + "import org.springframework.web.server.WebFilterChain", + "import reactor.core.publisher.Mono", + "import org.springframework.http.HttpStatus", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.web.server.WebHandler" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller", + "method_count": 83, + "algorithm": "CRX", + "grammar": "root ::= \"post\"?+ \"expectBody\"?+ \"uri\"?+ \"jsonPath\"?+ \"exchange\"?+ \"isEqualTo\"?+ \"expectStatus\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.job.BatchOwnershipService", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.BatchOwnershipException", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.nio.file.Path", + "import java.time.Duration", + "import java.time.LocalDateTime", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import eu.corentic.springrag.service.job.BatchNotFoundException", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.model.Source", + "import eu.corentic.springrag.service.chat.ChatService", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import kotlinx.coroutines.test.runTest", + "import org.springframework.http.codec.json.JacksonJsonDecoder", + "import org.springframework.http.codec.json.JacksonJsonEncoder", + "import tools.jackson.databind.json.JsonMapper", + "import tools.jackson.module.kotlin.KotlinModule", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import eu.corentic.springrag.security.service.PasswordPolicyViolationException", + "import eu.corentic.springrag.security.service.UserAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.DocumentNotFoundInKnowledgeBaseException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseSizeLimitExceededException", + "import eu.corentic.springrag.service.knowledgebase.InvalidKnowledgeBaseNameException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseNotFoundException", + "import eu.corentic.springrag.service.job.JobAlreadyCompleteException", + "import eu.corentic.springrag.service.job.BatchOwnerRequiredException", + "import eu.corentic.springrag.service.job.JobAlreadyRunningException", + "import eu.corentic.springrag.service.job.JobExecutionNotFoundException", + "import eu.corentic.springrag.service.job.JobInputValidationException", + "import java.io.ByteArrayInputStream", + "import kotlin.test.assertEquals", + "import org.springframework.core.io.buffer.DataBufferLimitException", + "import org.springframework.core.MethodParameter", + "import org.springframework.http.HttpHeaders", + "import org.springframework.http.HttpInputMessage", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.converter.HttpMessageNotReadableException", + "import org.springframework.web.method.annotation.MethodArgumentTypeMismatchException", + "import eu.corentic.springrag.service.knowledgebase.CreateKnowledgeBaseRequest", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseListItem", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseStatistics", + "import io.mockk.just", + "import io.mockk.runs", + "import java.time.Instant", + "import kotlinx.coroutines.runBlocking", + "import org.springframework.http.MediaType", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.mockk.slot", + "import java.io.File", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.web.reactive.function.BodyInserters" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/auth", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= (\"CREATED\" | \"LoginRequest\" | \"LoginResponse\" | \"OK\" | \"ROLE_USER\" | \"RegisterRequest\" | \"UNAUTHORIZED\" | \"User\" | \"UserAlreadyExistsException\" | \"assertEquals\" | \"assertThrows\" | \"body\" | \"every\" | \"findByUsername\" | \"generateToken\" | \"login\" | \"matches\" | \"register\" | \"registerUser\" | \"runBlocking\" | \"statusCode\" | \"token\" | \"username\")?+ \"init\"?+ \"name\"? \"Map\"?+ \"AuthController\"? \"role\"? \"assertTrue\"?", + "mdl_score": 34845, + "imports": [ + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.model.User", + "import eu.corentic.springrag.security.service.JwtService", + "import eu.corentic.springrag.security.service.UserAlreadyExistsException", + "import eu.corentic.springrag.security.service.UserService", + "import io.mockk.MockKAnnotations", + "import io.mockk.every", + "import io.mockk.impl.annotations.MockK", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.assertThrows", + "import org.springframework.http.HttpStatus", + "import org.springframework.security.crypto.password.PasswordEncoder" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/librechat", + "method_count": 46, + "algorithm": "CRX", + "grammar": "root ::= \"every\"? \"exchange\"?+ (\"get\" | \"post\")?+ \"expectStatus\"?+ \"uri\"?+ \"isOk\"? \"contentType\"?+ \"expectBody\"?+ \"jsonPath\"?+ \"isEqualTo\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalInvoker", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalResult", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.controller.GlobalExceptionHandler", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.port.AgentKnowledgeBasePort", + "import eu.corentic.springrag.service.port.DocumentIdPort", + "import eu.corentic.springrag.service.port.DocumentImageInfo", + "import eu.corentic.springrag.service.port.DocumentImagePort", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.service.port.VectorDocumentDeletionPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.test.UnconfinedTestDispatcher", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.http.HttpMethod", + "import org.springframework.http.MediaType", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.web.reactive.function.BodyInserters", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.controller.InvalidUploadRequestException", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import kotlinx.coroutines.test.runTest", + "import org.springframework.core.io.buffer.DefaultDataBufferFactory", + "import org.springframework.http.HttpHeaders", + "import org.springframework.http.codec.multipart.FilePart", + "import reactor.core.publisher.Flux", + "import kotlin.test.assertContains", + "import kotlin.test.assertFailsWith" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/web", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= \"runBlocking\"? \"verify\"? \"RuntimeException\"? \"controller\"? \"handleFileUpload\"?+ (\"every\" | \"knowledgeBaseExists\")?+ \"just\"?+ \"startBulkJob\"?+ \"filePart\"? \"any\"?+ (\"OK\" | \"assertEquals\" | \"statusCode\")?+ \"body\"? \"get\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.controller.UploadWorkflow", + "import eu.corentic.springrag.service.job.BatchOwnershipService", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.time.Duration", + "import java.time.Instant", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.http.HttpHeaders", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.codec.multipart.FilePart", + "import reactor.core.publisher.Flux", + "import reactor.core.publisher.Mono" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"return Neo4jTransactionManager(driver)\"? \"builder\"?+ \"return CommandLineRunner {\n try {\n driver.session().use { session ->\n logger.info { \\\"[NEO4J] Initializing schema constraints...\\\" }\n\n session.run(\n \\\"CREATE CONSTRAINT document_id_unique IF NOT EXISTS FOR (d:Document) REQUIRE d.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT page_id_unique IF NOT EXISTS FOR (p:Page) REQUIRE p.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT image_id_unique IF NOT EXISTS FOR (i:ImageData) REQUIRE i.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT text_id_unique IF NOT EXISTS FOR (t:TextElement) REQUIRE t.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT table_id_unique IF NOT EXISTS FOR (t:TableElement) REQUIRE t.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT header_id_unique IF NOT EXISTS FOR (h:SectionHeaderElement) REQUIRE h.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT picture_id_unique IF NOT EXISTS FOR (p:PictureElement) REQUIRE p.id IS UNIQUE\\\"\n )\n session.run(\n \\\"CREATE CONSTRAINT knowledge_base_id_unique IF NOT EXISTS FOR (kb:KnowledgeBase) REQUIRE kb.id IS UNIQUE\\\"\n )\n\n session.run(\\\"MATCH (d:Document) WHERE d.version IS NULL SET d.version = 0\\\")\n session.run(\\\"MATCH (p:Page) WHERE p.version IS NULL SET p.version = 0\\\")\n session.run(\\\"MATCH (i:ImageData) WHERE i.version IS NULL SET i.version = 0\\\")\n session.run(\\\"MATCH (t:TextElement) WHERE t.version IS NULL SET t.version = 0\\\")\n session.run(\\\"MATCH (t:TableElement) WHERE t.version IS NULL SET t.version = 0\\\")\n session.run(\\\"MATCH (p:PictureElement) WHERE p.version IS NULL SET p.version = 0\\\")\n session.run(\\\"MATCH (h:SectionHeaderElement) WHERE h.version IS NULL SET h.version = 0\\\")\n session.run(\\\"MATCH (k:KnowledgeBase) WHERE k.version IS NULL SET k.version = 0\\\")\n\n logger.info { \\\"[NEO4J] All unique constraints verified/created\\\" }\n }\n } catch (e: RuntimeException) {\n logger.error(e) { \\\"[NEO4J] Failed to initialize schema\\\" }\n throw e\n }\n }\"? \"Neo4jTransactionManager\"? \"chatMemoryRepository\"?+ \"CommandLineRunner\"? \"maxMessages\"?+ \"try\"? \"build\"?+ \"session\"?+ \"use\"?+ (\"info\" | \"run\")?+ \"catch\"? \"RuntimeException\"? \"error\"?+ \"throw e\"? \"throw\"?", + "mdl_score": 0, + "imports": [ + "import org.springframework.ai.chat.memory.ChatMemory", + "import org.springframework.ai.chat.memory.ChatMemoryRepository", + "import org.springframework.ai.chat.memory.MessageWindowChatMemory", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.neo4j.driver.Driver", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.context.annotation.Primary", + "import org.springframework.data.neo4j.core.transaction.Neo4jTransactionManager", + "import org.springframework.transaction.PlatformTransactionManager", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.CommandLineRunner" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"timeout\"? \"connectTimeout\"? (\"region\" | \"writeValueAsString\")?+ \"read\"? \"toMillis\"?+ \"coerceAtMost\"?+ \"MAX_VALUE\"? \"toLong\"?+ \"toInt\"?+ (\"CONNECT_TIMEOUT_MILLIS\" | \"END\" | \"InputType\" | \"LoggingCohereEmbeddingBedrockApi\" | \"ReactorClientHttpRequestFactory\" | \"ReadTimeoutHandler\" | \"SEARCH_DOCUMENT\" | \"SECONDS\" | \"Truncate\" | \"WriteTimeoutHandler\" | \"addHandlerLast\" | \"baseUrl\" | \"build\" | \"builder\" | \"create\" | \"debug\" | \"doOnConnected\" | \"embedding\" | \"embeddings\" | \"firstOrNull\" | \"getModelId\" | \"info\" | \"inputType\" | \"ofSeconds\" | \"option\" | \"readTimeout\" | \"requestFactory\" | \"responseTimeout\" | \"restClientBuilder\" | \"return OllamaApi.builder()\n .baseUrl(properties.baseUrl)\n .restClientBuilder(restClientBuilder)\n .build()\" | \"return ReactorClientHttpRequestFactory(httpClient)\" | \"return try {\n val response = super.embedding(request)\n logger.debug { \\\"Cohere embedding success: ${response.embeddings().size} embeddings\\\" }\n response\n } catch (e: Exception) {\n logger.error(e) { \\\"Cohere embedding failed: ${e.message}\\\" }\n throw e\n }\" | \"seconds\" | \"size\" | \"take\" | \"texts\" | \"trace\" | \"truncate\" | \"try\" | \"writeTimeout\")?+ \"catch\"? \"return BedrockCohereEmbeddingModel(api, options)\"? \"Exception\"? \"BedrockCohereEmbeddingModel\"? \"error\"?+ \"message\"? \"throw e\"? \"throw\"?", + "mdl_score": 0, + "imports": [ + "import io.netty.channel.ChannelOption", + "import io.netty.handler.timeout.ReadTimeoutHandler", + "import io.netty.handler.timeout.WriteTimeoutHandler", + "import java.util.concurrent.TimeUnit", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.http.client.ClientHttpRequestFactory", + "import org.springframework.http.client.ReactorClientHttpRequestFactory", + "import reactor.netty.http.client.HttpClient", + "import com.fasterxml.jackson.databind.ObjectMapper", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingModel", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingOptions", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingRequest", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingResponse", + "import org.springframework.ai.embedding.EmbeddingModel", + "import org.springframework.beans.factory.annotation.Qualifier", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.context.annotation.Primary", + "import software.amazon.awssdk.auth.credentials.AwsCredentialsProvider", + "import software.amazon.awssdk.regions.providers.AwsRegionProvider", + "import java.time.Duration", + "import org.springframework.ai.ollama.api.OllamaApi", + "import org.springframework.context.annotation.Profile", + "import org.springframework.web.client.RestClient" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/health", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"fromCallable\"?+ \"run\"?+ \"runWithCircuitBreaker\"? \"Supplier\"? \"listModels\"?+ \"action\"? \"models\"?+ \"throw throwable ?: IllegalStateException(\\\"Ollama circuit breaker fallback\\\")\"? \"subscribeOn\"?+ \"throw\"? \"boundedElastic\"?+ \"IllegalStateException\"? \"map\"?+ \"mapNotNull\"?+ \"name\"?+ \"listOf\"?+ \"filterNot\"?+ \"any\"?+ \"modelMatches\"? \"if\"? \"isEmpty\"?+ \"return true\"? \"up\"?+ \"substringBefore\"?+ (\"build\" | \"down\" | \"else\" | \"just\" | \"onErrorResume\" | \"withDetail\")?+ \"return normalizedRequired == normalizedAvailable\"?", + "mdl_score": 0, + "imports": [ + "import org.springframework.ai.ollama.api.OllamaApi", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.boot.health.contributor.Health", + "import org.springframework.boot.health.contributor.ReactiveHealthIndicator", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.context.annotation.Profile", + "import org.springframework.stereotype.Component", + "import java.util.function.Supplier", + "import reactor.core.publisher.Mono", + "import reactor.core.scheduler.Schedulers" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"assertThrows\"? \"IllegalArgumentException\"? \"java\"? \"OllamaClientProperties\"? \"EmbabelAiHttpClientProperties\"? \"Timeout\"?+ (\"assertEquals\" | \"baseUrl\" | \"ofSeconds\" | \"readTimeout\" | \"writeTimeout\")?+ \"timeout\"? \"connectTimeout\"? \"read\"?", + "mdl_score": 12825, + "imports": [ + "import java.time.Duration", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/health", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"`when`\"? \"listModels\"?+ \"thenThrow\"?+ \"thenReturn\"?+ \"RuntimeException\"? \"ListModelResponse\"?+ \"listOf\"?+ (\"Model\" | \"now\")?+ \"requireNotNull\"?+ \"OllamaHealthIndicator\"? \"NoOpCircuitBreakerFactory\"? \"health\"?+ \"block\"?+ \"assertEquals\"? \"status\"? \"code\"?", + "mdl_score": 0, + "imports": [ + "import java.time.Instant", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.`when`", + "import org.springframework.ai.ollama.api.OllamaApi" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/service/embedding", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"builder\"?+ (\"BedrockCohereEmbeddingModel\" | \"CapturingCohereApi\" | \"CohereEmbeddingResponse\" | \"EmbeddingRequest\" | \"FloatArray\" | \"InputType\" | \"NONE\" | \"SEARCH_DOCUMENT\" | \"Truncate\" | \"assertEquals\" | \"assertNotNull\" | \"build\" | \"call\" | \"capturedRequest\" | \"embed\" | \"inputType\" | \"listOf\" | \"map\" | \"println\" | \"readTree\" | \"return CohereEmbeddingResponse(\n \\\"test-id\\\",\n fakeEmbeddings,\n request.texts(),\n \\\"embeddings_floats\\\",\n null\n )\" | \"texts\" | \"truncate\" | \"writeValueAsString\")?+", + "mdl_score": 1027200, + "imports": [ + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingModel", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingOptions", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingRequest", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingResponse", + "import org.springframework.ai.embedding.EmbeddingRequest", + "import software.amazon.awssdk.auth.credentials.AnonymousCredentialsProvider", + "import software.amazon.awssdk.regions.Region", + "import java.time.Duration" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"Any\" | \"Builder\" | \"get\")+", + "mdl_score": 15, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/chat-memory/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"ChatMemoryConfig\"? \"Message\"? \"chatMemory\"?+ (\"Any\" | \"MutableMap\" | \"String\" | \"fun\" | \"mutableMapOf\")?+ \"repeat\"?+ \"MessageType\"? (\"add\" | \"makeMessage\")?+ \"USER\"? (\"assertEquals\" | \"get\" | \"size\" | \"text\")?+", + "mdl_score": 0, + "imports": [ + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.chat.memory.InMemoryChatMemoryRepository", + "import org.springframework.ai.chat.messages.Message", + "import org.springframework.ai.chat.messages.MessageType" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"fromCallable\"?+ (\"File\" | \"builder\")?+ \"health\"?+ \"subscribeOn\"?+ \"boundedElastic\"?+ (\"ByteArray\" | \"DocumentParsingRequest\" | \"GraphDocument\" | \"absolutePath\" | \"asDocumentId\" | \"asFilename\" | \"asJobId\" | \"asLogicalDocumentId\" | \"assertTrue\" | \"build\" | \"content\" | \"convertDocument\" | \"doTableStructure\" | \"down\" | \"else\" | \"emptyList\" | \"every\" | \"exists\" | \"filename\" | \"generatePageImages\" | \"getStatus\" | \"if\" | \"imagesScale\" | \"just\" | \"let\" | \"map\" | \"name\" | \"onErrorResume\" | \"options\" | \"readBytes\" | \"requireNotNull\" | \"up\" | \"value\" | \"withDetail\")?+ \"jobId\"? \"tables\"? \"parse\"?+ \"return ParsedDocument(graphDocument = graphDocument)\"? \"isNotEmpty\"?+ \"assertEquals\"? \"assertNull\"? \"ParsedDocument\"? \"graphDocument\"?", + "mdl_score": 0, + "imports": [ + "import ai.docling.serve.api.DoclingServeApi", + "import org.springframework.boot.health.contributor.Health", + "import org.springframework.boot.health.contributor.ReactiveHealthIndicator", + "import org.springframework.stereotype.Component", + "import reactor.core.publisher.Mono", + "import reactor.core.scheduler.Schedulers", + "import eu.corentic.springrag.service.docling.DoclingGraphDocumentMapper", + "import eu.corentic.springrag.service.docling.DoclingService", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.config.DoclingConfig", + "import java.io.File", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.core.io.ClassPathResource", + "import org.springframework.test.context.TestPropertySource", + "import ai.docling.core.DoclingDocument", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.every", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"IllegalStateException\" | \"bucket\" | \"error\" | \"generatePageImages\" | \"generatePictureImages\" | \"if\" | \"imageExportMode\" | \"includeImages\" | \"info\" | \"isBlank\" | \"s3Target\" | \"setOf\" | \"throw\" | \"throw IllegalStateException(errorMsg)\" | \"toFormats\" | \"useS3Target\")?+ \"Method\"? \"validateCriticalSettings\"? (\"DoclingServeJackson3Client\" | \"getDeclaredMethod\" | \"invoke\" | \"isAccessible\" | \"java\")?+ \"Builder\"? \"return builder\n .baseUrl(URI.create(config.baseUrl))\n .asyncPollInterval(Duration.ofMillis(config.pollIntervalMillis))\n .asyncTimeout(Duration.ofSeconds(config.timeoutSeconds))\n .build()\"? (\"baseUrl\" | \"create\")?+ \"asyncPollInterval\"?+ \"ofMillis\"?+ \"pollIntervalMillis\"? \"asyncTimeout\"?+ \"ofSeconds\"?+ \"timeoutSeconds\"? \"build\"?+", + "mdl_score": 0, + "imports": [ + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.client.DoclingServeJackson3Client", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import java.lang.reflect.Method", + "import java.net.URI", + "import java.time.Duration", + "import jakarta.validation.constraints.Min", + "import jakarta.validation.constraints.NotBlank", + "import jakarta.annotation.PostConstruct", + "import org.slf4j.LoggerFactory", + "import org.springframework.boot.context.properties.ConfigurationProperties", + "import org.springframework.validation.annotation.Validated" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/service/docling", + "method_count": 21, + "imports": [ + "import com.google.auth.oauth2.GoogleCredentials", + "import com.google.auth.oauth2.IdTokenCredentials", + "import com.google.auth.oauth2.IdTokenProvider", + "import ai.docling.core.DoclingDocument", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphImagePayload", + "import eu.corentic.springrag.model.GraphPage", + "import eu.corentic.springrag.model.GraphPictureElement", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Component", + "import java.util.Base64", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.api.convert.request.options.ConvertDocumentOptions", + "import ai.docling.serve.api.convert.request.options.ImageRefMode", + "import ai.docling.serve.api.convert.request.options.OcrEngine", + "import ai.docling.serve.api.convert.request.options.PdfBackend", + "import ai.docling.serve.api.convert.request.options.ProcessingPipeline", + "import ai.docling.serve.api.convert.request.options.OutputFormat", + "import ai.docling.serve.api.convert.request.source.FileSource", + "import ai.docling.serve.api.convert.request.target.InBodyTarget", + "import ai.docling.serve.api.convert.request.target.S3Target", + "import eu.corentic.springrag.config.DoclingConfig", + "import java.util.function.Supplier", + "import java.time.Duration", + "import jakarta.annotation.PostConstruct", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.stereotype.Service" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"return try {\n buildWithNoArgFactory(config)\n } catch (_: NoSuchMethodException) {\n buildWithClassLoaderFactory(config)\n }\"? \"assumeTrue\"?+ \"registerProperties\"?+ \"DoclingServeClientBuilderFactory\"? \"try\"? \"corentic\"? (\"ClassLoader\" | \"String\" | \"baseUrl\" | \"getMethod\" | \"invoke\" | \"java\" | \"javaClass\" | \"return buildMethod.invoke(configuredBuilder) as DoclingServeApi\")?+ \"buildWithNoArgFactory\"? \"springrag\"? \"classLoader\"? \"DoclingServeApi\"? \"testcontainers\"? \"return configureAndBuild(builder, config)\"? (\"ClassCastException\" | \"IllegalAccessException\" | \"IllegalStateException\" | \"InvocationTargetException\" | \"NoSuchMethodException\" | \"catch\" | \"cause\" | \"throw\" | \"throw IllegalStateException(\\\"Docling test client builder API is incompatible\\\", e)\" | \"throw IllegalStateException(\\\"Docling test client builder API is not accessible\\\", e)\" | \"throw IllegalStateException(\\\"Docling test client builder invocation failed\\\", e.cause ?: e)\" | \"throw IllegalStateException(\\\"Docling test client builder returned an unexpected type\\\", e)\")?+ \"GpuSupport\"? \"configureAndBuild\"? \"buildWithClassLoaderFactory\"? \"isDockerAvailable\"?+ \"start\"?+ \"pullAndWarmup\"?+ \"ollamaContainer\"?", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.testcontainers.junit.jupiter.Testcontainers", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.client.DoclingServeClientBuilderFactory", + "import java.lang.reflect.InvocationTargetException", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= \"DoclingConfig\"? \"assertThatThrownBy\"? \"baseUrl\"? \"validateCriticalSettings\"?+ (\"includeImages\" | \"options\")?+ \"isInstanceOf\"?+ \"imageExportMode\"? \"IllegalStateException\"? \"java\"? \"hasMessageContaining\"?+", + "mdl_score": 18, + "imports": [ + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.Test", + "import org.assertj.core.api.Assertions.assertThat", + "import org.assertj.core.api.Assertions.assertThatThrownBy", + "import org.junit.jupiter.api.Assertions.assertNull" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/health", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"`when`\"? (\"DoclingHealthIndicator\" | \"IllegalStateException\" | \"RuntimeException\" | \"assertEquals\" | \"block\" | \"build\" | \"builder\" | \"health\" | \"requireNotNull\" | \"status\" | \"thenReturn\" | \"thenThrow\")?+ \"code\"?", + "mdl_score": 685824, + "imports": [ + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.api.health.HealthCheckResponse", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.`when`" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/service/docling", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= \"options\"? \"mockk\"? \"DoclingDocument\"? (\"builder\" | \"document\")?+ \"jsonContent\"?+ (\"build\" | \"status\")?+ \"slot\"? \"ConvertDocumentRequest\"? \"every\"? \"convertSourceAsync\"?+ \"capture\"? \"completedFuture\"?+ \"convertDocument\"?+ \"toByteArray\"?+ \"captured\"?", + "mdl_score": 0, + "imports": [ + "import ai.docling.core.DoclingDocument", + "import eu.corentic.springrag.common.ids.asJobId", + "import java.util.Base64", + "import org.junit.jupiter.api.Assertions.assertArrayEquals", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.api.convert.request.ConvertDocumentRequest", + "import ai.docling.serve.api.convert.request.options.ImageRefMode", + "import ai.docling.serve.api.convert.request.options.OcrEngine", + "import ai.docling.serve.api.convert.request.options.OutputFormat", + "import ai.docling.serve.api.convert.request.options.PdfBackend", + "import ai.docling.serve.api.convert.request.options.ProcessingPipeline", + "import ai.docling.serve.api.convert.response.InBodyConvertDocumentResponse", + "import ai.docling.serve.api.convert.response.DocumentResponse", + "import eu.corentic.springrag.config.DoclingConfig", + "import eu.corentic.springrag.config.PipelineOptions", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import io.mockk.clearAllMocks", + "import tools.jackson.databind.ObjectMapper", + "import ai.docling.serve.api.convert.request.target.S3Target", + "import ai.docling.serve.api.convert.request.target.InBodyTarget", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify", + "import java.util.concurrent.CompletableFuture", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.assertThrows" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"Any\" | \"Builder\" | \"get\")+", + "mdl_score": 15, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/health", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= \"withDetail\"?+ \"build\"?+ \"onErrorResume\"?+ \"just\"?+", + "mdl_score": 4, + "imports": [ + "import org.neo4j.driver.Driver", + "import java.time.Duration", + "import org.springframework.boot.health.contributor.Health", + "import org.springframework.boot.health.contributor.ReactiveHealthIndicator", + "import org.springframework.stereotype.Component", + "import reactor.core.publisher.Mono", + "import com.google.common.util.concurrent.FutureCallback", + "import com.google.common.util.concurrent.Futures", + "import com.google.common.util.concurrent.ListenableFuture", + "import com.google.common.util.concurrent.MoreExecutors", + "import io.qdrant.client.QdrantClient", + "import java.util.concurrent.ExecutionException", + "import java.util.concurrent.TimeoutException", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Profile" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/model/graph", + "method_count": 9, + "algorithm": "CRX", + "grammar": "root ::= (\"id\" | \"if\" | \"jobId\" | \"pageNo\" | \"return false\" | \"return true\")?+ \"hashCode\"?+ \"return result\"?", + "mdl_score": 2568, + "imports": [ + "import java.time.Instant", + "import org.springframework.data.annotation.Version", + "import org.springframework.data.neo4j.core.schema.Id", + "import org.springframework.data.neo4j.core.schema.Node", + "import org.springframework.data.neo4j.core.schema.Relationship", + "import org.springframework.data.neo4j.core.schema.Property" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/repository", + "method_count": 24, + "algorithm": "CRX", + "grammar": "root ::= \"builder\"?+ \"build\"?+ \"query\"?+ \"return runWithCircuitBreaker { vectorStore.similaritySearch(request).map { it.toVectorChunk() } }\"? \"topK\"?+ \"runWithCircuitBreaker\"? \"filterExpression\"?+ \"similaritySearch\"?+ \"map\"?+ \"toVectorChunk\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.model.VectorChunk", + "import org.springframework.ai.document.Document", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import java.util.function.Supplier", + "import org.springframework.ai.vectorstore.SearchRequest", + "import org.springframework.ai.vectorstore.VectorStore", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Repository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/agent", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"return try {\n val existingId = agentRepository.findKnowledgeBaseIdByAgentId(agentId)\n if (existingId != null) return existingId\n doCreate(agentId)\n } catch (e: Exception) {\n // Concurrent thread created the agent+KB first \u2014 read and return their result.\n agentRepository.findKnowledgeBaseIdByAgentId(agentId) ?: throw e\n }\"? \"return agentRepository.findKnowledgeBaseIdByAgentId(agentId)\"? \"now\"?+ \"try\"? (\"KnowledgeBaseNode\" | \"save\")?+ (\"Exception\" | \"catch\" | \"doCreate\" | \"findKnowledgeBaseIdByAgentId\" | \"if\" | \"return existingId\")?+ \"AgentNode\"? \"throw e\"? \"return kbId\"? \"throw\"?", + "mdl_score": 3132, + "imports": [ + "import eu.corentic.springrag.model.graph.AgentNode", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.repository.graph.AgentRepository", + "import eu.corentic.springrag.repository.graph.KnowledgeBaseRepository", + "import eu.corentic.springrag.service.port.AgentKnowledgeBasePort", + "import org.springframework.stereotype.Service", + "import org.springframework.transaction.annotation.Transactional", + "import java.time.Instant" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/cleanup", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"info\"?+ (\"deleteByJobId\" | \"deleteByKnowledgeBaseId\" | \"jobId\" | \"knowledgeBaseId\" | \"value\")?+", + "mdl_score": 1685, + "imports": [ + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.service.graph.GraphIngestionOrchestrator", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.modulith.events.ApplicationModuleListener", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.repository.VectorRepository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/graph", + "method_count": 12, + "imports": [ + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphImagePayload", + "import eu.corentic.springrag.model.GraphPictureElement", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.model.graph.ImageData", + "import eu.corentic.springrag.model.graph.PageNode", + "import eu.corentic.springrag.model.graph.PictureElement", + "import eu.corentic.springrag.model.graph.TableElement", + "import eu.corentic.springrag.model.graph.TextElement", + "import eu.corentic.springrag.service.port.DocumentGraphJobPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import java.util.function.Supplier", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.stereotype.Component", + "import org.springframework.transaction.annotation.Propagation", + "import org.springframework.transaction.annotation.Transactional", + "import java.time.Instant", + "import java.util.concurrent.CompletableFuture", + "import java.util.concurrent.Executors" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/port/adapter", + "method_count": 45, + "imports": [ + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.model.PageTextElement", + "import eu.corentic.springrag.model.SourceImage", + "import eu.corentic.springrag.repository.graph.ImageDataRepository", + "import eu.corentic.springrag.repository.graph.TextElementRepository", + "import eu.corentic.springrag.repository.graph.TableElementRepository", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import java.util.Base64", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.repository.graph.DocumentJobNodeRepository", + "import eu.corentic.springrag.service.port.DocumentGraphJobPort", + "import java.time.Instant", + "import eu.corentic.springrag.service.port.DocumentIdPort", + "import eu.corentic.springrag.service.port.DocumentImageInfo", + "import eu.corentic.springrag.service.port.DocumentImagePort", + "import eu.corentic.springrag.repository.graph.GraphMaintenanceRepository", + "import eu.corentic.springrag.service.graph.GraphDeletePort", + "import eu.corentic.springrag.service.graph.GraphStorePort", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import eu.corentic.springrag.model.KnowledgeBase", + "import eu.corentic.springrag.model.KnowledgeBaseStats", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.repository.graph.KnowledgeBaseRepository", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import eu.corentic.springrag.service.port.VectorDocumentDeletionPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import eu.corentic.springrag.service.port.RetrievalPort" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/storage", + "method_count": 40, + "imports": [ + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.ObjectStorageProperties", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.stereotype.Component", + "import software.amazon.awssdk.auth.credentials.DefaultCredentialsProvider", + "import software.amazon.awssdk.regions.Region", + "import software.amazon.awssdk.services.s3.S3Client", + "import software.amazon.awssdk.services.s3.model.Delete", + "import software.amazon.awssdk.services.s3.model.DeleteObjectRequest", + "import software.amazon.awssdk.services.s3.model.DeleteObjectsRequest", + "import software.amazon.awssdk.services.s3.model.HeadObjectRequest", + "import software.amazon.awssdk.services.s3.model.ListObjectsV2Request", + "import software.amazon.awssdk.services.s3.model.NoSuchBucketException", + "import software.amazon.awssdk.services.s3.model.PutObjectRequest", + "import software.amazon.awssdk.services.s3.model.S3Exception", + "import software.amazon.awssdk.core.sync.RequestBody", + "import com.google.cloud.storage.BlobId", + "import com.google.cloud.storage.BlobInfo", + "import com.google.cloud.storage.Storage", + "import com.google.cloud.storage.StorageOptions", + "import java.net.URI", + "import software.amazon.awssdk.auth.credentials.AwsBasicCredentials", + "import software.amazon.awssdk.auth.credentials.StaticCredentialsProvider", + "import software.amazon.awssdk.services.s3.S3Configuration", + "import software.amazon.awssdk.services.s3.model.CreateBucketRequest", + "import software.amazon.awssdk.services.s3.model.HeadBucketRequest" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"assumeTrue\"?+ \"run\"?+ (\"recreateTestCollection\" | \"registerProperties\")?+ \"corentic\"? \"collectionPointCount\"?+ \"springrag\"? \"testcontainers\"? \"GpuSupport\"? \"isDockerAvailable\"?+ \"start\"?+ \"pullAndWarmup\"?+ \"ollamaContainer\"?", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport.recreateTestCollection", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import io.qdrant.client.QdrantClient", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.junit.jupiter.api.BeforeEach", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.springframework.test.context.TestPropertySource", + "import org.testcontainers.junit.jupiter.Testcontainers" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/repository/graph", + "method_count": 23, + "algorithm": "CRX", + "grammar": "root ::= \"saveAll\"?+ \"findById\"?+ (\"parse\" | \"runBlocking\")?+ \"listOf\"?+ \"orElseThrow\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.model.graph.ImageData", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.model.graph.PageNode", + "import eu.corentic.springrag.model.graph.TextElement", + "import java.time.Instant", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.test.annotation.DirtiesContext", + "import org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.BeforeEach", + "import eu.corentic.springrag.model.graph.TableElement", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.springframework.context.annotation.Import" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/system", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"runBlocking\"? \"setupTestCollection\"? \"listOf\"?+ (\"VectorChunk\" | \"mapOf\")?+ \"addChunks\"?+ \"searchSimilar\"?+ (\"any\" | \"asJobId\" | \"assertEquals\" | \"assertTrue\" | \"contains\" | \"deleteByJobId\" | \"fetchByJobId\" | \"isNotEmpty\" | \"metadata\" | \"single\" | \"size\" | \"text\")?+ \"isEmpty\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.test.annotation.DirtiesContext", + "import org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_CLASS" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"IllegalStateException\" | \"`when`\" | \"anyString\" | \"assertThrows\" | \"atLeastOnce\" | \"contains\" | \"java\" | \"neo4jSchemaInitializer\" | \"run\" | \"session\" | \"thenReturn\" | \"thenThrow\" | \"times\" | \"verify\")?+ \"mockk\"? \"close\"?+ \"Driver\"? \"Neo4jConfig\"? \"transactionManager\"?+ \"assertTrue\"? \"Neo4jTransactionManager\"?", + "mdl_score": 13300, + "imports": [ + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.neo4j.driver.Driver", + "import org.springframework.data.neo4j.core.transaction.Neo4jTransactionManager", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.mockito.ArgumentMatchers.anyString", + "import org.mockito.ArgumentMatchers.contains", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.times", + "import org.mockito.Mockito.atLeastOnce", + "import org.mockito.Mockito.verify", + "import org.mockito.Mockito.`when`", + "import org.neo4j.driver.Result", + "import org.neo4j.driver.Session" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/health", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= (\"HealthCheckReply\" | \"`when`\" | \"collectionExistsAsync\" | \"getDefaultInstance\" | \"healthCheckAsync\" | \"immediateFuture\" | \"thenReturn\" | \"verifyConnectivityAsync\")?+ \"immediateFailedFuture\"?+ \"completedFuture\"?+ \"failedFuture\"?+ (\"InterruptedException\" | \"TimeoutException\")? \"IllegalStateException\"? (\"Neo4jDriverHealthIndicator\" | \"QdrantVectorStoreHealthIndicator\" | \"assertEquals\" | \"assertTrue\" | \"block\" | \"code\" | \"currentThread\" | \"health\" | \"interrupted\" | \"isInterrupted\" | \"requireNotNull\" | \"status\")?+", + "mdl_score": 0, + "imports": [ + "import java.util.concurrent.CompletableFuture", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.neo4j.driver.Driver", + "import org.mockito.Mockito.`when`", + "import com.google.common.util.concurrent.Futures", + "import io.qdrant.client.QdrantClient", + "import io.qdrant.client.grpc.QdrantOuterClass", + "import java.util.concurrent.TimeoutException", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/model/graph", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= \"assertEquals\"?+ \"ImageData\"? \"hashCode\"?+ \"copy\"?+ \"assertNotEquals\"?", + "mdl_score": 21, + "imports": [ + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotEquals", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotEquals" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/repository", + "method_count": 19, + "algorithm": "CRX", + "grammar": "root ::= \"every\"? \"assertEquals\"? \"listOf\"?+ \"map\"?+ \"text\"? \"verify\"? \"delete\"?+ \"similaritySearch\"?+ \"any\"? \"match\"? \"String\"?+ \"SearchRequest\"? (\"contains\" | \"filterExpression\" | \"toString\")?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.verify", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.document.Document", + "import org.springframework.ai.vectorstore.SearchRequest", + "import org.springframework.ai.vectorstore.VectorStore", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/cleanup", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= (\"DocumentDeletionRequested\" | \"KnowledgeBaseDeletionRequested\" | \"asJobId\" | \"asKnowledgeBaseId\" | \"deleteByJobId\" | \"deleteByKnowledgeBaseId\" | \"every\" | \"onDocumentDeletionRequested\" | \"onKnowledgeBaseDeletionRequested\" | \"verify\")+", + "mdl_score": 388660, + "imports": [ + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.service.graph.GraphIngestionOrchestrator", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.verify", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.repository.VectorRepository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/graph", + "method_count": 30, + "algorithm": "CRX", + "grammar": "root ::= \"every\"? \"asDocumentId\"?+ \"asJobId\"?+ \"findOrCreateInactive\"?+ \"asLogicalDocumentId\"?+ \"any\"?+ \"asFilename\"?+ \"stubDocumentGraphJob\"?", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphImagePayload", + "import eu.corentic.springrag.model.GraphPage", + "import eu.corentic.springrag.model.GraphPictureElement", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.service.port.DocumentGraphJobPort", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import io.mockk.*", + "import io.mockk.impl.annotations.MockK", + "import io.mockk.junit5.MockKExtension", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.extension.ExtendWith" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/port/adapter", + "method_count": 28, + "imports": [ + "import eu.corentic.springrag.model.graph.ImageData", + "import eu.corentic.springrag.model.graph.TableElement", + "import eu.corentic.springrag.model.graph.TextElement", + "import eu.corentic.springrag.repository.graph.ImageDataRepository", + "import eu.corentic.springrag.repository.graph.TableElementRepository", + "import eu.corentic.springrag.repository.graph.TextElementRepository", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.util.Optional", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.repository.graph.DocumentJobNodeRepository", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import java.time.Instant", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import eu.corentic.springrag.repository.graph.GraphMaintenanceRepository", + "import io.mockk.just", + "import io.mockk.runs", + "import eu.corentic.springrag.model.KnowledgeBase", + "import eu.corentic.springrag.repository.graph.KnowledgeBaseRepository", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/storage", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"assertNull\"? \"parseS3Location\"? \"error\"?+ (\"assertEquals\" | \"bucket\")?+ \"key\"?", + "mdl_score": 182, + "imports": [ + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNull" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"Any\" | \"Builder\" | \"get\")+", + "mdl_score": 15, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/integrationTest/kotlin/eu/corentic/springrag/service/chat", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"runBlocking\"? \"mockk\"? \"ChatService\"? \"ChatResponse\"? \"every\"? \"listCapabilities\"? \"defaultAgentId\"? \"emptyList\"?+ \"RagInvocation\"? \"RagRequest\"? \"of\"?+ \"http\"?+ \"coEvery\"? (\"answer\" | \"assertEquals\" | \"chatWithSources\" | \"coVerify\" | \"invoke\")?+", + "mdl_score": 95, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import org.springframework.boot.SpringBootConfiguration", + "import org.springframework.boot.autoconfigure.EnableAutoConfiguration", + "import org.springframework.context.annotation.Bean", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.every", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.mockk", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.test.context.ActiveProfiles" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/main/kotlin/eu/corentic/springrag/service/chat", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"let\"?+ \"info\"?+ \"KnowledgeBaseId\"? \"defaultAgentId\"?+ (\"RagInvocation\" | \"RagRequest\" | \"invoke\" | \"return ragAgentInvocationGateway.invoke(\n RagInvocation(\n request = request,\n executionContext = AgentExecutionContext.http()\n )\n )\" | \"return ragAgentInvocationGateway.invoke(\n RagInvocation(\n request = request,\n executionContext = AgentExecutionContext.http(contextId = conversationId)\n )\n )\")?+ \"listCapabilities\"?+ \"http\"?+ \"map\"?+ \"filter\"?+ \"id\"? \"AgentCapabilityDescriptor\"?", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.capability.isExposedOverHttp", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import jakarta.annotation.PostConstruct", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Service" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 15, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport.recreateTestCollection", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import io.qdrant.client.QdrantClient", + "import java.time.Duration", + "import java.time.Instant", + "import java.util.UUID", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.junit.jupiter.api.BeforeEach", + "import org.neo4j.driver.Driver", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.jdbc.core.JdbcTemplate", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.springframework.test.context.TestPropertySource", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.testcontainers.junit.jupiter.Testcontainers", + "import java.sql.Timestamp", + "import org.springframework.ai.chat.memory.ChatMemory", + "import org.springframework.ai.chat.memory.ChatMemoryRepository", + "import org.springframework.ai.chat.memory.MessageWindowChatMemory", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.boot.SpringBootConfiguration", + "import org.springframework.boot.autoconfigure.EnableAutoConfiguration", + "import org.springframework.boot.context.properties.ConfigurationPropertiesScan", + "import org.springframework.context.annotation.ComponentScan", + "import org.springframework.data.neo4j.repository.config.EnableNeo4jRepositories", + "import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories", + "import org.springframework.jdbc.datasource.DataSourceTransactionManager", + "import org.springframework.transaction.PlatformTransactionManager", + "import javax.sql.DataSource", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.client.DoclingServeClientBuilderFactory", + "import java.lang.reflect.InvocationTargetException" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/systemTest/kotlin/eu/corentic/springrag/system", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"runBlocking\"? \"setupTestCollection\"? \"addChunks\"?+ \"listOf\"?+ \"VectorChunk\"? \"mapOf\"?+ (\"ChatResponse\" | \"SessionChatRequest\" | \"String\" | \"adminClient\" | \"answer\" | \"any\" | \"assertEquals\" | \"assertNotNull\" | \"assertTrue\" | \"atMost\" | \"await\" | \"blockFirst\" | \"bodyValue\" | \"contains\" | \"conversationId\" | \"exchange\" | \"expectBody\" | \"expectStatus\" | \"get\" | \"isEqualTo\" | \"isNotBlank\" | \"isOk\" | \"jsonPath\" | \"lowercase\" | \"ofSeconds\" | \"post\" | \"responseBody\" | \"returnResult\" | \"text\" | \"untilAsserted\" | \"uri\" | \"value\")?+ \"isEmpty\"?", + "mdl_score": 3008, + "imports": [ + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.controller.SessionChatRequest", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository", + "import java.time.Duration", + "import kotlinx.coroutines.runBlocking", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.chat.memory.ChatMemory", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.test.web.reactive.server.returnResult" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/test/kotlin/eu/corentic/springrag/service/chat", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? \"assertEquals\"? \"answer\"? \"coVerify\"? (\"ChatResponse\" | \"RagInvocation\" | \"RagRequest\" | \"asKnowledgeBaseId\" | \"coEvery\" | \"defaultAgentId\" | \"emptyList\" | \"every\" | \"http\" | \"invoke\" | \"listCapabilities\")?+ \"ChatService\"?", + "mdl_score": 639936, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.every", + "import io.mockk.mockk", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import org.junit.jupiter.api.BeforeEach" + ], + "arg_patterns": {} + }, + { + "label": "modules/common/src/main/kotlin/eu/corentic/springrag/common", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= \"when\" \"Ok\"? \"Err\"?", + "mdl_score": 4, + "imports": [], + "arg_patterns": {} + }, + { + "label": "modules/common/src/main/kotlin/eu/corentic/springrag/common/ids", + "method_count": 18, + "imports": [], + "arg_patterns": {} + }, + { + "label": "modules/common/src/test/kotlin/eu/corentic/springrag/common/ids", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"assertEquals\"? (\"IllegalArgumentException\" | \"assertFailsWith\" | \"of\" | \"value\")?+", + "mdl_score": 2768, + "imports": [ + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFailsWith" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/integrationTest/kotlin/eu/corentic/springrag/service/job", + "method_count": 34, + "imports": [ + "import com.ninjasquad.springmockk.MockkBean", + "import eu.corentic.springrag.batch.DocumentIngestionJobConfig", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.processor.DocumentProcessingItemProcessor", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import io.mockk.clearMocks", + "import io.mockk.every", + "import java.io.File", + "import java.time.Duration", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.test.context.ActiveProfiles", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.springframework.jdbc.core.JdbcTemplate", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.batch.listener.BatchJobListener", + "import eu.corentic.springrag.batch.listener.SimpleDocumentTrackingListener", + "import eu.corentic.springrag.batch.partition.DocumentPartitioner", + "import eu.corentic.springrag.batch.reader.FileBasedDocumentItemReader", + "import eu.corentic.springrag.batch.writer.GraphStoreItemWriter", + "import java.nio.file.Files", + "import java.util.concurrent.CountDownLatch", + "import java.util.concurrent.TimeUnit", + "import java.util.concurrent.atomic.AtomicLong", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.core.launch.JobOperator", + "import org.junit.jupiter.api.Assertions.assertNull", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import java.util.concurrent.ConcurrentHashMap", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.context.annotation.Profile" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch", + "method_count": 16, + "imports": [ + "import eu.corentic.springrag.batch.listener.BatchJobListener", + "import eu.corentic.springrag.batch.listener.DocumentActivationWriteListener", + "import eu.corentic.springrag.batch.listener.DocumentIngestionStageWriteListener", + "import eu.corentic.springrag.batch.listener.SimpleDocumentTrackingListener", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.partition.DocumentPartitioner", + "import eu.corentic.springrag.batch.processor.DocumentProcessingItemProcessor", + "import eu.corentic.springrag.batch.reader.FileBasedDocumentItemReader", + "import eu.corentic.springrag.batch.writer.DocumentActivationWriter", + "import eu.corentic.springrag.batch.writer.DocumentIngestionStageWriter", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.config.BatchProperties", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import javax.sql.DataSource", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.batch.core.configuration.annotation.StepScope", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.job.builder.JobBuilder", + "import org.springframework.batch.core.repository.JobRepository", + "import org.springframework.batch.core.partition.PartitionHandler", + "import org.springframework.batch.core.partition.support.TaskExecutorPartitionHandler", + "import org.springframework.batch.core.step.Step", + "import org.springframework.batch.core.step.builder.StepBuilder", + "import org.springframework.batch.core.step.skip.SkipPolicy", + "import org.springframework.batch.core.listener.SkipListener", + "import org.springframework.batch.infrastructure.item.database.JdbcCursorItemReader", + "import org.springframework.batch.infrastructure.item.database.builder.JdbcCursorItemReaderBuilder", + "import org.springframework.beans.factory.annotation.Qualifier", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.core.task.TaskExecutor", + "import org.springframework.core.retry.RetryPolicy", + "import org.springframework.dao.TransientDataAccessException", + "import org.springframework.transaction.PlatformTransactionManager", + "import org.springframework.util.backoff.FixedBackOff", + "import java.io.IOException", + "import eu.corentic.springrag.service.chunk.DocumentChunkService", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import org.springframework.batch.infrastructure.item.ItemProcessor", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/listener", + "method_count": 16, + "algorithm": "CRX", + "grammar": "root ::= (\"filename\" | \"jobId\" | \"recordFailure\")?+ \"forEach\"?+ \"markFailed\"?+ \"documentId\"?", + "mdl_score": 93, + "imports": [ + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.batch.core.BatchStatus", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.listener.JobExecutionListener", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import org.springframework.batch.core.listener.ItemWriteListener", + "import org.springframework.batch.core.listener.SkipListener", + "import org.springframework.batch.infrastructure.item.Chunk", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import org.springframework.batch.core.listener.ItemProcessListener" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/model", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= (\"DocumentInput\" | \"content\" | \"contentEquals\" | \"documentId\" | \"fileStorageUri\" | \"filename\" | \"if\" | \"javaClass\" | \"jobId\" | \"knowledgeBaseId\" | \"logicalDocumentId\" | \"return false\" | \"return true\" | \"submittedBy\")?+ (\"contentHashCode\" | \"hashCode\")?+ \"entries\"? \"return result\"? \"filter\"?+ (\"key\" | \"startsWith\")?+ \"endsWith\"?+ \"mapNotNull\"?+ \"value\"? (\"Boolean\" | \"DocumentParsingError\" | \"ERROR\" | \"GenericError\" | \"Int\" | \"Long\" | \"NetworkTimeoutError\" | \"String\" | \"ValidationError\" | \"WARNING\" | \"else\" | \"let\" | \"return when (errorType) {\n \\\"DocumentParsingError\\\" -> ProcessingError.DocumentParsingError(\n filename = this[\\\"document.doc${index}.error.filename\\\"] as? String ?: \\\"unknown\\\",\n line = this[\\\"document.doc${index}.error.line\\\"] as? Int,\n message = message ?: \\\"Unknown parsing error\\\",\n retryable = retryable,\n severity = severity?.let { ErrorSeverity.valueOf(it) } ?: ErrorSeverity.ERROR\n )\n \\\"NetworkTimeoutError\\\" -> ProcessingError.NetworkTimeoutError(\n timeoutMs = this[\\\"document.doc${index}.error.timeoutMs\\\"] as? Long ?: 30000,\n message = message ?: \\\"Unknown timeout error\\\",\n retryable = retryable,\n severity = severity?.let { ErrorSeverity.valueOf(it) } ?: ErrorSeverity.WARNING\n )\n \\\"ValidationError\\\" -> ProcessingError.ValidationError(\n field = this[\\\"document.doc${index}.error.field\\\"] as? String ?: \\\"unknown\\\",\n value = this[\\\"document.doc${index}.error.value\\\"] as? String ?: \\\"unknown\\\",\n message = message ?: \\\"Unknown validation error\\\",\n retryable = retryable,\n severity = severity?.let { ErrorSeverity.valueOf(it) } ?: ErrorSeverity.ERROR\n )\n else -> ProcessingError.GenericError(\n exceptionType = errorType ?: \\\"UnknownError\\\",\n message = message ?: \\\"Unknown error\\\",\n retryable = retryable,\n severity = severity?.let { ErrorSeverity.valueOf(it) } ?: ErrorSeverity.ERROR\n )\n }\" | \"valueOf\" | \"when\")?+ \"return ErrorSummary(\n totalErrors = errors.size,\n retryableErrors = errors.count { it.contains(\\\"timeout\\\") || it.contains(\\\"retryable\\\") },\n firstError = errors.firstOrNull()\n )\"? \"ErrorSummary\"? \"size\"? \"count\"?+ \"contains\"?+ \"firstOrNull\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import java.time.Instant" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/partition", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"values\"? \"mutableMapOf\"?+ \"firstOrNull\"?+ \"getString\"?+ (\"Exception\" | \"ExecutionContext\" | \"Filename\" | \"IllegalStateException\" | \"List\" | \"String\" | \"UUID\" | \"appendPath\" | \"catch\" | \"compareTo\" | \"createEmptyPartitions\" | \"else\" | \"error\" | \"exists\" | \"fileName\" | \"filenameFromUri\" | \"filter\" | \"for\" | \"forEachIndexed\" | \"getDefault\" | \"getPathMatcher\" | \"if\" | \"info\" | \"isDirectory\" | \"isEmpty\" | \"isNotEmpty\" | \"isObjectStorageUri\" | \"isRegularFile\" | \"list\" | \"listObjects\" | \"listOf\" | \"listTrackedFilenames\" | \"logPartitioningInfo\" | \"map\" | \"mapNotNull\" | \"matches\" | \"message\" | \"of\" | \"put\" | \"putInt\" | \"putString\" | \"queueDocuments\" | \"randomUUID\" | \"removeSuffix\" | \"resolveFiles\" | \"resolvePath\" | \"return Files.list(rootPath).use { stream ->\n stream\n .filter { Files.isRegularFile(it) }\n .filter { matcher.matches(it.fileName) }\n .filter { Files.size(it) > 0L }\n .sorted { a, b -> a.fileName.toString().compareTo(b.fileName.toString()) }\n .toList()\n }\" | \"return createEmptyPartitions(gridSize, \\\"ERROR: No inputPath provided\\\")\" | \"return partitions\" | \"size\" | \"sorted\" | \"throw\" | \"throw IllegalStateException(\\\"Input path does not exist: $rootPath\\\")\" | \"throw IllegalStateException(\\\"Input path is not a directory: $rootPath\\\")\" | \"throw IllegalStateException(\\\"Invalid inputPath: $normalizedInputPath\\\")\" | \"toString\" | \"toUri\" | \"try\" | \"use\" | \"util\" | \"value\" | \"warn\")?+ \"toList\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import java.nio.file.FileSystems", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import kotlin.streams.toList", + "import org.springframework.batch.core.configuration.annotation.StepScope", + "import org.springframework.batch.core.partition.Partitioner", + "import org.springframework.batch.infrastructure.item.ExecutionContext", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/reader", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"poll\"?+ (\"DocumentInput\" | \"IllegalStateException\" | \"KnowledgeBaseId\" | \"List\" | \"String\" | \"containsKey\" | \"debug\" | \"documentVersionId\" | \"else\" | \"error\" | \"exists\" | \"filenameFromUri\" | \"forEach\" | \"get\" | \"getResource\" | \"identityHashCode\" | \"if\" | \"info\" | \"inputStream\" | \"isNotEmpty\" | \"isObjectStorageUri\" | \"isReadable\" | \"it\" | \"java\" | \"let\" | \"loadObject\" | \"logicalDocumentId\" | \"mapNotNull\" | \"name\" | \"objectExists\" | \"of\" | \"offer\" | \"partitionedFiles\" | \"readBytes\" | \"requireNotNull\" | \"return\" | \"return DocumentInput(\n jobId = resolvedJobId,\n documentId = documentId,\n logicalDocumentId = logicalDocumentId,\n filename = resolvedFilename,\n content = content,\n fileStorageUri = StorageUri.of(uri),\n knowledgeBaseId = resolvedKnowledgeBaseId,\n submittedBy = submittedBy\n )\" | \"return null\" | \"size\" | \"throw\" | \"throw IllegalStateException(\\\"Object not found at $uri\\\")\" | \"throw IllegalStateException(\\\"Resource not readable: $uri\\\")\" | \"use\" | \"value\" | \"warn\" | \"when\")?+ (\"clear\" | \"initialize\")?+", + "mdl_score": 532496, + "imports": [ + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.document.DocumentIdentity", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.batch.infrastructure.item.ExecutionContext", + "import org.springframework.batch.infrastructure.item.ItemStreamReader", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.core.io.ResourceLoader", + "import java.util.concurrent.ConcurrentLinkedQueue" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/writer", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"items\"? \"forEach\"?+ (\"addChunks\" | \"chunks\" | \"content\" | \"debug\" | \"documentId\" | \"else\" | \"enforce\" | \"fileStorageUri\" | \"filename\" | \"graphDocument\" | \"if\" | \"input\" | \"isEmpty\" | \"jobId\" | \"knowledgeBaseId\" | \"let\" | \"logicalDocumentId\" | \"pictures\" | \"size\" | \"stageDocumentGraph\" | \"submittedBy\" | \"tables\" | \"texts\" | \"toLong\" | \"upsertStaging\" | \"value\" | \"warn\")?+ \"activate\"?+", + "mdl_score": 71388, + "imports": [ + "import eu.corentic.springrag.service.job.DocumentActivationService", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import org.springframework.batch.infrastructure.item.Chunk", + "import org.springframework.batch.infrastructure.item.ItemWriter", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.service.chunk.EmbeddingInputGuard", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 26, + "imports": [ + "import javax.sql.DataSource", + "import org.springframework.batch.core.configuration.support.JdbcDefaultBatchConfiguration", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.core.task.TaskDecorator", + "import org.springframework.core.task.TaskExecutor", + "import org.springframework.core.task.VirtualThreadTaskExecutor", + "import org.springframework.core.task.support.TaskExecutorAdapter", + "import org.springframework.jdbc.datasource.DataSourceTransactionManager", + "import org.springframework.transaction.PlatformTransactionManager", + "import org.springframework.transaction.annotation.Isolation", + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.StorageUri", + "import jakarta.annotation.PostConstruct", + "import jakarta.validation.constraints.NotBlank", + "import java.net.URI", + "import java.nio.file.Path", + "import java.time.Duration", + "import org.slf4j.LoggerFactory", + "import org.springframework.boot.context.properties.ConfigurationProperties", + "import org.springframework.validation.annotation.Validated" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/chunk", + "method_count": 18, + "algorithm": "CRX", + "grammar": "root ::= \"trim\"?+ \"if\" \"isBlank\"?+", + "mdl_score": 4, + "imports": [ + "import eu.corentic.springrag.config.HybridChunkingConfig", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import org.springframework.stereotype.Service", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.config.EmbabelModelProperties", + "import kotlin.math.min", + "import com.knuddels.jtokkit.Encodings", + "import com.knuddels.jtokkit.api.Encoding", + "import com.knuddels.jtokkit.api.EncodingType" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/document", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"joinToString\"? (\"lowercase\" | \"trim\" | \"value\")?+ \"format\"?+ \"getInstance\"?+ \"digest\"?+ \"toByteArray\"?+ \"toHex\"?+ (\"return DocumentId.of(\\\"doc-$hex\\\")\" | \"return LogicalDocumentId.of(\\\"ldoc-$hex\\\")\")? \"of\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import java.security.MessageDigest" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/job", + "method_count": 62, + "imports": [ + "import java.sql.Timestamp", + "import java.time.Instant", + "import org.springframework.jdbc.core.JdbcTemplate", + "import org.springframework.stereotype.Component", + "from ingestion_batch_ownership", + "import eu.corentic.springrag.common.DomainException", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Service", + "import eu.corentic.springrag.model.event.DocumentActivationFailed", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import org.springframework.modulith.events.ApplicationModuleListener", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import org.springframework.context.ApplicationEventPublisher", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.batch.model.ErrorSeverity", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import java.sql.ResultSet", + "import org.springframework.transaction.annotation.Transactional", + "from ingestion_document_tracking", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import org.springframework.jdbc.core.RowMapper", + "from ingestion_document_state", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.repository.JobRepository", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import org.springframework.core.io.ResourceLoader", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.core.launch.JobOperator", + "import java.util.UUID", + "import org.springframework.batch.core.job.parameters.JobParametersBuilder", + "import java.io.File", + "import java.util.*", + "import org.springframework.batch.core.launch.JobExecutionAlreadyRunningException", + "import org.springframework.batch.core.launch.JobInstanceAlreadyCompleteException", + "import eu.corentic.springrag.batch.DocumentIngestionJobConfig", + "import org.springframework.batch.core.launch.NoSuchJobException", + "import eu.corentic.springrag.batch.model.ErrorSummary", + "import org.springframework.batch.core.BatchStatus", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import java.net.URI", + "import java.nio.file.Path", + "import org.springframework.scheduling.annotation.Scheduled", + "import org.springframework.util.FileSystemUtils" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch", + "method_count": 17, + "imports": [ + "import eu.corentic.springrag.config.BatchProperties", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import io.mockk.mockk", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder", + "import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseType", + "import java.io.IOException", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import org.springframework.core.retry.RetryPolicy", + "import org.springframework.dao.TransientDataAccessResourceException", + "import org.springframework.util.backoff.FixedBackOff", + "import org.springframework.batch.core.step.skip.SkipPolicy", + "import kotlin.test.assertNotNull", + "import org.springframework.batch.core.listener.ItemProcessListener", + "import org.springframework.batch.core.listener.JobExecutionListener" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/listener", + "method_count": 34, + "imports": [ + "import eu.corentic.springrag.config.StorageProperties", + "import java.io.IOException", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.time.Duration", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.batch.core.BatchStatus", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.core.job.parameters.JobParametersBuilder", + "import org.springframework.batch.test.MetaDataInstanceFactory", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.mockk.mockk", + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.runs", + "import io.mockk.verify", + "import org.springframework.batch.infrastructure.item.Chunk", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import java.io.EOFException", + "import java.net.SocketTimeoutException", + "import javax.net.ssl.SSLException", + "import kotlin.test.assertEquals", + "import eu.corentic.springrag.model.VectorChunk", + "import io.mockk.slot" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/model", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"mapOf\"?+ \"DocumentInput\"? (\"assertNotEquals\" | \"severity\")? \"String\"?+ \"asJobId\"?+ \"Any\"? \"asDocumentId\"?+ \"requireNotNull\"?+ \"asLogicalDocumentId\"?+ \"getDocumentError\"?+ \"asFilename\"?+ \"assertTrue\"? \"byteArrayOf\"?+ \"ProcessingError\"? \"asStorageUri\"?+ \"asKnowledgeBaseId\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotEquals", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/partition", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= (\"resolve\" | \"writeString\")?+ \"mockk\"? \"DocumentTrackingRepository\"? (\"any\" | \"asJobId\" | \"assertEquals\" | \"assertTrue\" | \"containsAll\" | \"emptyList\" | \"every\" | \"getString\" | \"listOf\" | \"listTrackedFilenames\" | \"map\" | \"match\" | \"partition\" | \"partitioner\" | \"queueDocuments\" | \"size\" | \"sorted\" | \"value\" | \"values\" | \"verify\")?+ \"error\"?+ \"all\"?+ \"getInt\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.verify", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/processor", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"clearAllMocks\"? \"DocumentInput\"? (\"DocumentParsingRequest\" | \"GraphDocument\" | \"ParsedDocument\" | \"RuntimeException\" | \"VectorChunk\" | \"any\" | \"asDocumentId\" | \"asFilename\" | \"asJobId\" | \"asKnowledgeBaseId\" | \"asLogicalDocumentId\" | \"assertEquals\" | \"assertNotNull\" | \"assertThrows\" | \"byteArrayOf\" | \"content\" | \"createChunks\" | \"documentId\" | \"emptyList\" | \"every\" | \"filename\" | \"graphDocument\" | \"input\" | \"jobId\" | \"listOf\" | \"logicalDocumentId\" | \"parse\" | \"process\" | \"toList\" | \"verify\" | \"withArg\")?+ (\"chunks\" | \"knowledgeBaseId\")?", + "mdl_score": 86178481, + "imports": [ + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.chunk.DocumentChunkService", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.clearAllMocks", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.util.UUID", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.assertThrows" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/reader", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= (\"DefaultResourceLoader\" | \"File\" | \"FileBasedDocumentItemReader\" | \"absolutePath\" | \"byteArrayOf\" | \"core\" | \"io\" | \"open\" | \"springframework\" | \"writeBytes\")?+ \"batch\"? \"infrastructure\"? \"item\"? \"ExecutionContext\"?+ \"read\"?+ \"assertNull\"? \"assertNotNull\"? \"assertEquals\"? \"filename\"? \"value\"?", + "mdl_score": 5820, + "imports": [ + "import eu.corentic.springrag.service.document.DocumentIdentity", + "import java.io.File", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/writer", + "method_count": 14, + "algorithm": "CRX", + "grammar": "root ::= \"emptyList\"?+ \"runTest\"? \"write\"?+ \"ProcessedDocument\"? \"coVerify\"? \"Chunk\"? \"DocumentInput\"? \"stageDocumentGraph\"?+ \"listOf\"?+ \"asJobId\"?+ \"any\"?+ \"asDocumentId\"?+ \"asLogicalDocumentId\"?+ \"asFilename\"?+ \"byteArrayOf\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.service.job.DocumentActivationService", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import org.junit.jupiter.api.Test", + "import org.springframework.batch.infrastructure.item.Chunk", + "import kotlin.test.assertFailsWith", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.chunk.EmbeddingInputGuard", + "import eu.corentic.springrag.service.chunk.EmbeddingInputTooLargeException", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import io.mockk.verify", + "import io.mockk.*", + "import io.mockk.impl.annotations.MockK", + "import io.mockk.junit5.MockKExtension", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.extension.ExtendWith" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/chunk", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"HybridChunkingConfig\"? \"service\"? \"GraphDocument\"? \"listOf\"?+ (\"GraphTableElement\" | \"GraphTextElement\")? \"createChunks\"?+ \"asJobId\"?+ \"asDocumentId\"?+ \"asLogicalDocumentId\"?+ \"asFilename\"?+ \"ParsedDocument\"? (\"assertEquals\" | \"size\")?+ \"assertTrue\"? \"all\"?+ \"metadata\"? \"Int\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.config.HybridChunkingConfig", + "import eu.corentic.springrag.config.EmbabelModelProperties", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.ParsedDocument", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/job", + "method_count": 49, + "imports": [ + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFailsWith", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.model.event.DocumentActivationFailed", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.just", + "import io.mockk.runs", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import org.springframework.context.ApplicationEventPublisher", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import java.time.LocalDateTime", + "import kotlin.test.assertNull", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.job.parameters.JobParametersBuilder", + "import org.springframework.batch.core.repository.JobRepository", + "import java.io.File", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.springframework.core.io.DefaultResourceLoader", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertSame", + "import org.junit.jupiter.api.assertThrows", + "import org.slf4j.MDC", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.launch.JobOperator", + "import kotlin.test.assertNotNull", + "import io.mockk.slot", + "import org.junit.jupiter.api.Assertions.assertNotEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.springframework.batch.core.BatchStatus", + "import org.springframework.batch.core.launch.JobExecutionAlreadyRunningException", + "import org.springframework.batch.core.launch.JobInstanceAlreadyCompleteException", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.test.MetaDataInstanceFactory", + "import kotlin.test.assertTrue", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.config.StorageProperties", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.time.Duration", + "import java.time.Instant", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.io.TempDir" + ], + "arg_patterns": {} + }, + { + "label": "modules/knowledgebase/ports/src/main/kotlin/eu/corentic/springrag/model", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"return stats.canAcceptMoreContent(additionalBytes, sizeLimitBytes)\"? \"return sizeInBytes + additionalBytes <= sizeLimitBytes\"? (\"return copy(\n stats = stats.applySizeDelta(sizeDelta),\n updatedAt = Instant.now()\n )\" | \"return copy(sizeInBytes = sizeInBytes + sizeDelta)\" | \"return copy(updatedAt = Instant.now())\")? \"canAcceptMoreContent\"?+ \"copy\"? \"applySizeDelta\"?+ \"now\"?+", + "mdl_score": 39, + "imports": [ + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import java.time.Instant" + ], + "arg_patterns": {} + }, + { + "label": "modules/knowledgebase/src/main/kotlin/eu/corentic/springrag/service/knowledgebase", + "method_count": 11, + "algorithm": "CRX", + "grammar": "root ::= \"stats\"? \"of\"?+ (\"debug\" | \"info\")?+ \"documentCount\"? \"findById\"?+ \"toInt\"?+ \"throw KnowledgeBaseNotFoundException(kbId)\"? \"throw\"? \"KnowledgeBaseNotFoundException\"?", + "mdl_score": 10, + "imports": [ + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.KnowledgeBase", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.boot.CommandLineRunner", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import java.time.Instant", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import org.springframework.context.ApplicationEventPublisher", + "import org.springframework.stereotype.Service", + "import org.springframework.transaction.annotation.Transactional", + "import java.util.*" + ], + "arg_patterns": {} + }, + { + "label": "modules/knowledgebase/src/test/kotlin/eu/corentic/springrag/service/knowledgebase", + "method_count": 16, + "algorithm": "CRX", + "grammar": "root ::= \"parse\"?+ \"corentic\"? \"springrag\"? \"model\"? \"KnowledgeBase\"?+ (\"asKnowledgeBaseId\" | \"every\" | \"findById\")?+", + "mdl_score": 267, + "imports": [ + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import jakarta.validation.Validation", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.slot", + "import io.mockk.verify", + "import java.time.Instant", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.springframework.context.ApplicationEventPublisher" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/main/kotlin/eu/corentic/springrag/security/config", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= (\"Boolean\" | \"getProperty\" | \"java\")?+ \"CommandLineRunner\"? \"UserDetailsRepositoryReactiveAuthenticationManager\"? \"BCryptPasswordEncoder\"? \"request\"? \"acceptsProfiles\"?+ \"setPasswordEncoder\"?+ \"headers\"? \"of\"?+ \"return manager\"? \"getFirst\"?+ \"activeProfiles\"? \"AUTHORIZATION\"? \"isEmpty\"?+ \"return http\n // Temporary: Thymeleaf pages may post forms; keep CSRF for browser endpoints.\n // Long-term: JWT-only API (no cookie auth), so this can be revisited.\n .csrf {\n it.csrfTokenRepository(CookieServerCsrfTokenRepository.withHttpOnlyFalse())\n it.requireCsrfProtectionMatcher(\n AndServerWebExchangeMatcher(\n CsrfWebFilter.DEFAULT_CSRF_MATCHER,\n NegatedServerWebExchangeMatcher(\n // CSRF is only relevant for browser cookie-based interactions.\n // LibreChat calls our /librechat/** endpoints server-to-server and won't send CSRF tokens.\n ServerWebExchangeMatchers.pathMatchers(\\\"/api/**\\\", \\\"/mcp/**\\\", \\\"/librechat/**\\\")\n )\n )\n )\n }\n .httpBasic { it.disable() }\n .formLogin {\n if (!enableFormLogin) {\n it.disable()\n }\n }\n .logout { it.disable() }\n .authenticationManager(authenticationManager)\n .authorizeExchange { exchange ->\n if (permitAll) {\n exchange.anyExchange().permitAll()\n } else {\n exchange\n // Public assets and auth endpoints\n .pathMatchers(\\\"/api/auth/**\\\", \\\"/login\\\", \\\"/logout\\\", \\\"/librechat/**\\\").permitAll()\n .pathMatchers(\\\"/actuator/health/**\\\", \\\"/mcp/**\\\").permitAll()\n .apply {\n if (permitLibreChat) {\n pathMatchers(\\\"/librechat/**\\\").permitAll()\n } else {\n pathMatchers(\\\"/librechat/**\\\").authenticated()\n }\n }\n .pathMatchers(\\\"/css/**\\\", \\\"/js/**\\\", \\\"/images/**\\\", \\\"/webjars/**\\\").permitAll()\n .pathMatchers(\\\"/\\\", \\\"/upload\\\", \\\"/jobs\\\", \\\"/chat\\\", \\\"/knowledge-bases\\\", \\\"/web/**\\\")\n .hasAnyAuthority(\\\"ROLE_USER\\\", \\\"ROLE_ADMIN\\\")\n .anyExchange().authenticated()\n }\n }\n .addFilterAt(jwtAuthenticationFilter, SecurityWebFiltersOrder.AUTHENTICATION)\n .build()\"? \"csrf\"?+ \"csrfTokenRepository\"?+ \"withHttpOnlyFalse\"?+ \"requireCsrfProtectionMatcher\"?+ \"AndServerWebExchangeMatcher\"? \"DEFAULT_CSRF_MATCHER\"? \"NegatedServerWebExchangeMatcher\"? (\"ROLE_ADMIN\" | \"anyExchange\" | \"apply\" | \"authenticated\" | \"authenticationManager\" | \"authorizeExchange\" | \"disable\" | \"else\" | \"findByUsername\" | \"formLogin\" | \"hasAnyAuthority\" | \"httpBasic\" | \"if\" | \"info\" | \"logout\" | \"pathMatchers\" | \"permitAll\" | \"registerUser\")?+ \"ROLE_USER\"? \"addFilterAt\"?+ \"startsWith\"?+ \"AUTHENTICATION\"? \"substring\"?+ \"build\"?+ \"when\"? \"parseToken\"?+ (\"Err\" | \"Ok\" | \"Outcome\" | \"UsernamePasswordAuthenticationToken\" | \"authorities\" | \"contextWrite\" | \"filter\" | \"return chain.filter(exchange)\" | \"return chain.filter(exchange)\n .contextWrite(ReactiveSecurityContextHolder.withAuthentication(authentication))\" | \"username\" | \"value\" | \"withAuthentication\")?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.service.JwtService", + "import org.springframework.http.HttpHeaders", + "import org.springframework.security.authentication.UsernamePasswordAuthenticationToken", + "import org.springframework.security.core.context.ReactiveSecurityContextHolder", + "import org.springframework.stereotype.Component", + "import org.springframework.web.server.ServerWebExchange", + "import org.springframework.web.server.WebFilter", + "import org.springframework.web.server.WebFilterChain", + "import reactor.core.publisher.Mono", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.security.config.annotation.method.configuration.EnableReactiveMethodSecurity", + "import org.springframework.security.config.annotation.web.reactive.EnableWebFluxSecurity", + "import org.springframework.security.config.web.server.SecurityWebFiltersOrder", + "import org.springframework.security.config.web.server.ServerHttpSecurity", + "import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.security.web.server.SecurityWebFilterChain", + "import org.springframework.security.authentication.ReactiveAuthenticationManager", + "import org.springframework.security.core.userdetails.ReactiveUserDetailsService", + "import org.springframework.security.authentication.UserDetailsRepositoryReactiveAuthenticationManager", + "import org.springframework.security.web.server.csrf.CookieServerCsrfTokenRepository", + "import org.springframework.security.web.server.csrf.CsrfWebFilter", + "import org.springframework.security.web.server.util.matcher.AndServerWebExchangeMatcher", + "import org.springframework.security.web.server.util.matcher.NegatedServerWebExchangeMatcher", + "import org.springframework.security.web.server.util.matcher.ServerWebExchangeMatchers", + "import org.springframework.core.env.Environment", + "import org.springframework.core.env.Profiles", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.service.UserService", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.CommandLineRunner", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/main/kotlin/eu/corentic/springrag/security/service", + "method_count": 10, + "algorithm": "CRX", + "grammar": "root ::= \"if\"? \"parser\"?+ \"verifyWith\"?+ \"build\"?+ \"parseSignedClaims\"?+ \"payload\"?", + "mdl_score": 6, + "imports": [ + "import eu.corentic.springrag.security.repository.UserRepository", + "import org.springframework.security.core.userdetails.ReactiveUserDetailsService", + "import org.springframework.security.core.userdetails.User", + "import org.springframework.security.core.userdetails.UserDetails", + "import org.springframework.stereotype.Service", + "import reactor.core.publisher.Mono", + "import reactor.core.scheduler.Schedulers", + "import eu.corentic.springrag.common.DomainException", + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.model.User", + "import io.jsonwebtoken.ExpiredJwtException", + "import io.jsonwebtoken.Jwts", + "import io.jsonwebtoken.MalformedJwtException", + "import io.jsonwebtoken.UnsupportedJwtException", + "import io.jsonwebtoken.security.Keys", + "import io.jsonwebtoken.security.SecurityException", + "import java.nio.charset.StandardCharsets", + "import java.util.*", + "import javax.crypto.SecretKey", + "import eu.corentic.springrag.security.config.JwtProperties", + "import org.springframework.security.core.GrantedAuthority", + "import org.springframework.security.core.authority.SimpleGrantedAuthority", + "import java.util.UUID", + "import org.springframework.data.relational.core.mapping.event.BeforeConvertCallback", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.security.model.Role", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.transaction.annotation.Transactional" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/test/kotlin/eu/corentic/springrag/security/config", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"passwordEncoder\"?+ \"http\"?+ \"assertTrue\"? \"ReactiveAuthenticationManager\"? \"BCryptPasswordEncoder\"? \"empty\"?+ (\"ROLE_ADMIN\" | \"any\" | \"every\" | \"findByUsername\" | \"mockk\" | \"registerUser\" | \"run\" | \"seedUsers\" | \"verify\")?+ \"ROLE_USER\"? \"parseToken\"?+ \"JwtService\"? \"Ok\"?+ \"Err\"?+ \"JwtAuthenticationFilter\"? \"ParsedJwt\"?+ \"Malformed\"?+ \"springSecurityFilterChain\"?+ (\"AUTHORIZATION\" | \"AtomicReference\" | \"Authentication\" | \"SimpleGrantedAuthority\" | \"WebFilterChain\" | \"assertEquals\" | \"assertNull\" | \"authentication\" | \"block\" | \"build\" | \"doOnNext\" | \"filter\" | \"from\" | \"get\" | \"getContext\" | \"header\" | \"listOf\" | \"name\" | \"requireNotNull\" | \"set\" | \"then\")?+ \"assertNotNull\"? \"authorities\"? \"toList\"?+", + "mdl_score": 0, + "imports": [ + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.service.JwtService", + "import eu.corentic.springrag.security.service.JwtValidationError", + "import io.mockk.every", + "import io.mockk.mockk", + "import java.util.concurrent.atomic.AtomicReference", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import org.springframework.http.HttpHeaders", + "import org.springframework.mock.http.server.reactive.MockServerHttpRequest", + "import org.springframework.mock.web.server.MockServerWebExchange", + "import org.springframework.security.core.Authentication", + "import org.springframework.security.core.authority.SimpleGrantedAuthority", + "import org.springframework.security.core.context.ReactiveSecurityContextHolder", + "import org.springframework.web.server.WebFilterChain", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.springframework.mock.env.MockEnvironment", + "import org.springframework.security.authentication.ReactiveAuthenticationManager", + "import org.springframework.security.config.web.server.ServerHttpSecurity", + "import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder", + "import reactor.core.publisher.Mono", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.service.UserService", + "import io.mockk.just", + "import io.mockk.runs", + "import io.mockk.verify" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/test/kotlin/eu/corentic/springrag/security/service", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= \"every\"? \"JwtService\"? \"existsByUsername\"?+ \"JwtProperties\"? \"any\"? \"assertThrows\"? \"PasswordPolicyViolationException\"? \"java\"? \"registerUser\"?+ \"assertEquals\"? \"errorCode\"?", + "mdl_score": 481, + "imports": [ + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.model.User", + "import eu.corentic.springrag.security.config.JwtProperties", + "import io.jsonwebtoken.Jwts", + "import io.jsonwebtoken.security.Keys", + "import java.nio.charset.StandardCharsets", + "import java.util.UUID", + "import java.util.Date", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.security.repository.UserRepository", + "import io.mockk.MockKAnnotations", + "import io.mockk.every", + "import io.mockk.impl.annotations.MockK", + "import io.mockk.verify", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.BeforeEach", + "import org.springframework.security.crypto.password.PasswordEncoder" + ], + "arg_patterns": {} + }, + { + "label": "platform/test-support/src/main/kotlin/eu/corentic/springrag/testcontainers", + "method_count": 13, + "imports": [ + "import com.github.dockerjava.api.model.DeviceRequest", + "import org.testcontainers.DockerClientFactory", + "import org.testcontainers.containers.GenericContainer", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import io.qdrant.client.QdrantClient", + "import io.qdrant.client.grpc.Collections.Distance", + "import io.qdrant.client.grpc.Collections.VectorParams", + "import java.util.concurrent.ExecutionException", + "import eu.corentic.springrag.testcontainers.GpuSupport.withGpuIfAvailable", + "import java.io.File", + "import java.time.Duration", + "import org.testcontainers.containers.BindMode", + "import org.testcontainers.containers.Neo4jContainer", + "import org.testcontainers.containers.PostgreSQLContainer", + "import org.testcontainers.containers.wait.strategy.Wait", + "import org.testcontainers.junit.jupiter.Container" + ], + "arg_patterns": {} + }, + { + "label": "platform/test-support/src/test/kotlin/eu/corentic/springrag/testcontainers", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"@\"? \"Suppress\"?+ (\"ArgumentMatchers\" | \"CollectionConfig\" | \"CollectionInfo\" | \"CollectionOperationResponse\" | \"CollectionParams\" | \"Collections\" | \"Cosine\" | \"Distance\" | \"ExecResult\" | \"GenericContainer\" | \"IllegalStateException\" | \"InterruptedException\" | \"ListenableFuture\" | \"Mockito\" | \"RuntimeException\" | \"VectorParams\" | \"VectorsConfig\" | \"`when`\" | \"any\" | \"anyString\" | \"apply\" | \"assertEquals\" | \"assertThrows\" | \"assertTrue\" | \"build\" | \"collectionPointCount\" | \"createCollectionAsync\" | \"currentThread\" | \"deleteCollectionAsync\" | \"eq\" | \"execInContainer\" | \"get\" | \"getCollectionInfoAsync\" | \"getDefaultInstance\" | \"immediateFailedFuture\" | \"immediateFuture\" | \"interrupted\" | \"isInterrupted\" | \"java\" | \"mock\" | \"mockito\" | \"newBuilder\" | \"pullAndWarmup\" | \"recreateTestCollection\" | \"setConfig\" | \"setDistance\" | \"setParams\" | \"setSize\" | \"setVectorsConfig\" | \"thenReturn\" | \"thenThrow\" | \"times\" | \"verify\" | \"with\")?+ \"message\"? \"contains\"?+", + "mdl_score": 473418, + "imports": [ + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.times", + "import org.mockito.Mockito.verify", + "import org.testcontainers.containers.Container", + "import org.testcontainers.containers.GenericContainer", + "import com.google.common.util.concurrent.Futures", + "import com.google.common.util.concurrent.ListenableFuture", + "import io.qdrant.client.QdrantClient", + "import io.qdrant.client.grpc.Collections", + "import org.junit.jupiter.api.assertThrows", + "import org.mockito.ArgumentMatchers.any", + "import org.mockito.Mockito.`when`", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "(other)", + "method_count": 6, + "imports": [], + "arg_patterns": {} + } + ], + "total_methods": 1609 + }, + { + "language": ".js", + "conventions": [ + { + "label": "compose/patches", + "method_count": 17, + "imports": [], + "arg_patterns": { + "require": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "getFiles": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "other", + "lit", + "other" + ] + } + ] + }, + "tool": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "generateShortLivedToken": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Set": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "filterFilesByAgentAccess": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "new": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "setTimeout": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "Map": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "clearTimeout": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "EmbeddingPollerImpl": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "testing/steps", + "method_count": 68, + "imports": [ + "import { Given, When, Then } from '@cucumber/cucumber';", + "import { expect } from '@playwright/test';", + "import { BeforeAll, AfterAll, Before, After, setDefaultTimeout } from '@cucumber/cucumber';" + ], + "arg_patterns": { + "Then": { + "occurrences": 40, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 40, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "When": { + "occurrences": 54, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 54, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "expect": { + "occurrences": 40, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 14, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "Given": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "fetch": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "createAgent": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "setDefaultTimeout": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Before": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "After": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "testing/support", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= (\"await\" | \"catch\" | \"chromium\" | \"close\" | \"launch\" | \"newContext\" | \"process\")?+ \"return\"? \"newPage\"? \"Date\"?+ \"now\"? \"toString\"?", + "mdl_score": 7112, + "imports": [ + "import { chromium } from '@playwright/test';", + "import { setWorldConstructor } from '@cucumber/cucumber';" + ], + "arg_patterns": { + "setWorldConstructor": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "(other)", + "method_count": 1, + "imports": [], + "arg_patterns": {} + } + ], + "total_methods": 89 + }, + { + "language": ".java", + "conventions": [], + "total_methods": 0 + }, + { + "language": ".go", + "conventions": [ + { + "label": "tools/setup-ui", + "method_count": 44, + "imports": [ + "import (" + ], + "arg_patterns": { + "initialModel": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "runStart": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "buildSteps": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "errorStyle": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "summarizeConfig": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "accent": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "muted": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "banner": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "len": { + "occurrences": 42, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "make": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "other", + "other", + "call" + ] + } + ] + }, + "writeExport": { + "occurrences": 8, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "other", + "call" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "var", + "var", + "other" + ] + } + ] + }, + "append": { + "occurrences": 51, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "var", + "call" + ] + }, + { + "count": 9, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "string": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "newConfig": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "float64": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "sectionTitle": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "sortedKeys": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "removeString": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "isSensitiveKey": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "repoRoot": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "shellEscape": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "writeEnvFile": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + } + ], + "total_methods": 44 + } +] diff --git a/experiments/results/round20_ast_verify/ragsak_grammars.json b/experiments/results/round20_ast_verify/ragsak_grammars.json new file mode 100644 index 0000000..333a881 --- /dev/null +++ b/experiments/results/round20_ast_verify/ragsak_grammars.json @@ -0,0 +1,4140 @@ +[ + { + "language": ".kt", + "conventions": [ + { + "label": "agents", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"slot\"? (\"defaultCapabilityId\" | \"summarize\")? \"ToolInvocationRequest\"? \"ToolingRequest\"? \"ToolInvocationResult\"? (\"String\" | \"answer\" | \"any\" | \"assertEquals\" | \"capture\" | \"captured\" | \"every\" | \"generateText\" | \"invoke\" | \"invokeTools\" | \"promptRunner\" | \"toolProfile\" | \"verify\")?+ \"prompt\"? \"contains\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationGateway", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.PromptRunner", + "import eu.corentic.springrag.agent.tooling.embabel.DEFAULT_TOOL_PROFILE", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationAction", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationRequest", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationResult", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "agents/capability/ports/src/main/kotlin/eu/corentic/springrag/agent/capability", + "method_count": 5, + "algorithm": "CRX", + "grammar": "root ::= \"listCapabilities\"? \"DescribedAgentCapability\"? \"AgentExecutionContext\"? \"firstOrNull\"?+ \"TransportExposedAgentCapability\"? \"id\"? \"return AgentCapabilityDescriptor(\n id = id,\n capabilityType = capabilityType,\n displayName = describedCapability?.displayName ?: id,\n description = describedCapability?.description,\n exposedOverHttp = exposedCapability?.exposedOverHttp ?: false,\n exposedOverMcp = exposedCapability?.exposedOverMcp ?: false\n )\"? \"AgentCapabilityDescriptor\"? \"displayName\"? \"description\"? \"exposedOverHttp\"? \"exposedOverMcp\"?", + "mdl_score": 2051, + "imports": [], + "arg_patterns": {} + }, + { + "label": "agents/capability/support/src/main/kotlin/eu/corentic/springrag/agent/capability/support", + "method_count": 5, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.AgentCapabilityRegistry", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.asCoroutineDispatcher", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import java.util.concurrent.Executors", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationAuthorizer", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationGateway", + "import eu.corentic.springrag.agent.capability.AgentCapabilityResolver" + ], + "arg_patterns": {} + }, + { + "label": "agents/capability/support/src/test/kotlin/eu/corentic/springrag/agent/capability/support", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? \"TestRequest\"? (\"AgentCapabilityDescriptor\" | \"DefaultAgentCapabilityDirectory\" | \"IllegalStateException\" | \"assertEquals\" | \"assertFailsWith\" | \"authorize\" | \"capabilityDescriptors\" | \"coEvery\" | \"coVerify\" | \"defaultCapabilityId\" | \"every\" | \"id\" | \"invoke\" | \"listOf\" | \"message\" | \"resolve\" | \"verify\")+ (\"any\" | \"listCapabilities\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityRegistry", + "import io.mockk.every", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationAuthorizer", + "import eu.corentic.springrag.agent.capability.AgentCapabilityResolver", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.verify", + "import kotlinx.coroutines.test.runTest", + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFailsWith" + ], + "arg_patterns": {} + }, + { + "label": "agents/examples/simple-rag/src/main/kotlin/eu/corentic/springrag/example/rag/simple", + "method_count": 9, + "imports": [ + "import eu.corentic.springrag.model.VectorChunk", + "import org.slf4j.LoggerFactory", + "import org.springframework.ai.chat.client.ChatClient", + "import tools.jackson.databind.ObjectMapper", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.support.RagDocumentSupport", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.withContext", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/examples/simple-rag/src/test/kotlin/eu/corentic/springrag/example/rag/simple", + "method_count": 14, + "imports": [ + "import eu.corentic.springrag.model.VectorChunk", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.chat.client.ChatClient", + "import org.springframework.ai.chat.client.ChatClient.CallResponseSpec", + "import org.springframework.ai.chat.client.ChatClient.ChatClientRequestSpec", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.verify", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import io.mockk.clearAllMocks", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import tools.jackson.databind.json.JsonMapper", + "import tools.jackson.module.kotlin.KotlinModule" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel", + "method_count": 58, + "algorithm": "CRX", + "grammar": "root ::= \"shouldRetrieve\"? \"buildObservationContext\"? (\"ASK\" | \"ChatResponse\" | \"EmbabelJudgeDecision\" | \"Exception\" | \"JudgeOutcome\" | \"ResponseDraft\" | \"RetrievedEvidence\" | \"String\" | \"WORKFLOW_ORIGIN_CAPABILITY_KEY\" | \"WORKFLOW_TRANSPORT_KEY\" | \"advisors\" | \"agent\" | \"agents\" | \"allowAsk\" | \"allowRetrieve\" | \"applyRetrieveCost\" | \"askCost\" | \"asksSoFar\" | \"budgetRemaining\" | \"build\" | \"builder\" | \"call\" | \"canAffordRetrieve\" | \"catch\" | \"chatOptions\" | \"confidence\" | \"consumeBudget\" | \"contains\" | \"content\" | \"conversationId\" | \"copy\" | \"debug\" | \"decision\" | \"decisionState\" | \"docs\" | \"draftAnswer\" | \"else\" | \"emptyList\" | \"enoughEvidence\" | \"entity\" | \"equals\" | \"error\" | \"evidence\" | \"expandContext\" | \"find\" | \"get\" | \"if\" | \"ifBlank\" | \"info\" | \"invoke\" | \"isEmpty\" | \"isNotBlank\" | \"isNotEmpty\" | \"isNullOrBlank\" | \"java\" | \"joinToString\" | \"knowledgeBaseId\" | \"length\" | \"let\" | \"lowercase\" | \"maxRetrievalRounds\" | \"memoryContext\" | \"message\" | \"name\" | \"nextAction\" | \"of\" | \"options\" | \"orEmpty\" | \"originCapabilityId\" | \"param\" | \"prompt\" | \"promptClient\" | \"refinedQuery\" | \"removePrefix\" | \"removeSuffix\" | \"request\" | \"resultOfType\" | \"retrievalRounds\" | \"retrieve\" | \"retrieveCost\" | \"return false\" | \"return null\" | \"return this\" | \"return true\" | \"run\" | \"runWithCircuitBreaker\" | \"simpleName\" | \"size\" | \"system\" | \"take\" | \"takeIf\" | \"text\" | \"transport\" | \"trim\" | \"trimIndent\" | \"try\" | \"user\" | \"warn\" | \"withConversationId\" | \"withObservationContext\" | \"withWorkflowStep\")?+ \"map\"?+ \"hasDefaultKb\"? \"coerceIn\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.resultOfType", + "import com.embabel.agent.core.Identities", + "import com.embabel.agent.core.ProcessOptions", + "import com.embabel.agent.core.support.InMemoryBlackboard", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.model.ChatResponse", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.withContext", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.stereotype.Component", + "import org.springframework.stereotype.Service", + "import kotlin.math.max", + "import eu.corentic.springrag.agent.rag.support.RagDocumentSupport", + "import eu.corentic.springrag.model.Source", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.ai.chat.memory.ChatMemory", + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.annotation.Condition", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.domain.io.UserInput", + "import eu.corentic.springrag.agent.summarizer.SummarizeRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseQueryPort", + "import io.micrometer.common.KeyValue", + "import io.micrometer.common.KeyValues", + "import org.springframework.ai.chat.client.observation.ChatClientObservationContext", + "import org.springframework.ai.chat.client.observation.DefaultChatClientObservationConvention", + "import io.micrometer.observation.ObservationRegistry", + "import java.util.function.Supplier", + "import org.springframework.ai.chat.client.ChatClient", + "import org.springframework.ai.chat.model.ChatModel", + "import org.springframework.ai.chat.client.advisor.PromptChatMemoryAdvisor", + "import org.springframework.ai.chat.prompt.ChatOptions", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/main/kotlin/eu/corentic/springrag/agent/rag/embabel/librechat", + "method_count": 13, + "imports": [ + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.annotation.Condition", + "import com.embabel.agent.api.common.ActionContext", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.agent.rag.embabel.ConversationMemoryContext", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelJudgeDecision", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagDecisionPolicy", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowObservationContext", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowObservationConvention", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowPromptService", + "import eu.corentic.springrag.agent.rag.embabel.JudgeOutcome", + "import eu.corentic.springrag.agent.rag.embabel.RagDecisionState", + "import eu.corentic.springrag.agent.rag.embabel.RetrievedEvidence", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalResult", + "import eu.corentic.springrag.agent.rag.support.RagDocumentSupport", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Service", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.Identities", + "import com.embabel.agent.core.ProcessOptions", + "import com.embabel.agent.core.resultOfType", + "import com.embabel.agent.core.support.InMemoryBlackboard", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalInvoker", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/agent/rag/embabel", + "method_count": 36, + "algorithm": "CRX", + "grammar": "root ::= \"removeFirst\"?+ \"messageWindowMemory\"? \"unmockkAll\"? (\"mockkObject\" | \"runTest\")? \"return ChatResponse(listOf(Generation(AssistantMessage(content))))\"? \"add\"?+ (\"ASSISTANT\" | \"Agent\" | \"AgentProcess\" | \"AssistantMessage\" | \"ChatGraphLookupPort\" | \"ChatResponse\" | \"Companion\" | \"ConversationMemoryContext\" | \"DEFAULT_CONVERSATION_ID\" | \"DefaultEmbabelRagResponseInvoker\" | \"DirectAnswerDecision\" | \"EmbabelJudgeDecision\" | \"EmbabelLibreChatRetrievalAgent\" | \"EmbabelPlatformRagAgent\" | \"EmbabelRagDecisionPolicy\" | \"EmbabelRagWorkflowAgentProperties\" | \"EmbabelWorkflowObservationContext\" | \"EmbabelWorkflowObservationConvention\" | \"EmbabelWorkflowPromptService\" | \"Generation\" | \"InMemoryChatMemoryRepository\" | \"JudgeOutcome\" | \"LibreChatRetrievalRequest\" | \"NOOP\" | \"NoOpCircuitBreakerFactory\" | \"PageTextElement\" | \"ProcessOptions\" | \"Prompt\" | \"RagDecisionState\" | \"RagInvocation\" | \"RagRequest\" | \"RecordingChatModel\" | \"RetrievalPort\" | \"RetrievalQueryDraft\" | \"RetrievedEvidence\" | \"SpringAiEmbabelWorkflowPromptService\" | \"USER\" | \"UserMessage\" | \"VectorChunk\" | \"VectorDocumentPort\" | \"WORKFLOW_ORIGIN_CAPABILITY_KEY\" | \"WORKFLOW_STEP_KEY\" | \"WORKFLOW_TRANSPORT_KEY\" | \"advisors\" | \"agents\" | \"answer\" | \"any\" | \"anyMatch\" | \"applyRetrieveCost\" | \"asKnowledgeBaseId\" | \"assertEquals\" | \"assertNull\" | \"assertTrue\" | \"availableKnowledgeBases\" | \"blackboard\" | \"build\" | \"builder\" | \"capture\" | \"captured\" | \"chatMemoryRepository\" | \"checkKnowledgeBase\" | \"contains\" | \"context\" | \"contextId\" | \"conversationId\" | \"copy\" | \"createAgentProcessFrom\" | \"decision\" | \"decisionState\" | \"docs\" | \"draftAnswer\" | \"draftClarification\" | \"emptyList\" | \"enoughEvidence\" | \"every\" | \"executionContext\" | \"findExpandedTableMarkdown\" | \"findTextOnSamePage\" | \"first\" | \"get\" | \"getLowCardinalityKeyValues\" | \"hasDefaultKb\" | \"http\" | \"invoke\" | \"isEmpty\" | \"java\" | \"judgeDecision\" | \"judgeEvidence\" | \"key\" | \"knowledgeBaseId\" | \"last\" | \"listKnowledgeBases\" | \"listOf\" | \"mapOf\" | \"maxMessages\" | \"message\" | \"messageType\" | \"mockk\" | \"name\" | \"nextAction\" | \"normalize\" | \"of\" | \"options\" | \"orEmpty\" | \"outcome\" | \"prompt\" | \"prompts\" | \"query\" | \"request\" | \"requireNotNull\" | \"resultOfType\" | \"retrievalRounds\" | \"retrieveInitialEvidence\" | \"retrieveMoreEvidence\" | \"run\" | \"searchByJobIds\" | \"searchSimilar\" | \"single\" | \"size\" | \"slot\" | \"stream\" | \"systemMessage\" | \"text\" | \"userMessage\" | \"value\" | \"verify\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.Agent", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.AgentProcess", + "import com.embabel.agent.core.ProcessOptions", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.mockkObject", + "import io.mockk.slot", + "import io.mockk.unmockkAll", + "import io.mockk.verify", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import kotlinx.coroutines.test.runTest", + "import eu.corentic.springrag.model.PageTextElement", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.springframework.ai.chat.memory.ChatMemory", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseListItem", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseQueryPort", + "import org.springframework.ai.chat.client.ChatClientRequest", + "import org.springframework.ai.chat.client.observation.ChatClientObservationContext", + "import org.springframework.ai.chat.prompt.Prompt", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import io.micrometer.observation.ObservationRegistry", + "import org.springframework.ai.chat.memory.InMemoryChatMemoryRepository", + "import org.springframework.ai.chat.memory.MessageWindowChatMemory", + "import org.springframework.ai.chat.messages.AssistantMessage", + "import org.springframework.ai.chat.messages.MessageType", + "import org.springframework.ai.chat.messages.UserMessage", + "import org.springframework.ai.chat.model.ChatModel", + "import org.springframework.ai.chat.model.ChatResponse", + "import org.springframework.ai.chat.model.Generation", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelJudgeDecision", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagDecisionPolicy", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagWorkflowAgentProperties", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelWorkflowPromptService", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.service.port.VectorDocumentPort" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/embabel/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/ports/src/main/kotlin/eu/corentic/springrag/agent/rag", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapability", + "import eu.corentic.springrag.agent.capability.AgentCapabilityHandler", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.agent.capability.AgentCapabilityInvocationGateway" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/ports/src/test/kotlin/eu/corentic/springrag/agent/rag", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/ports/src/test/kotlin/eu/corentic/springrag/model", + "method_count": 3, + "imports": [ + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/support/src/main/kotlin/eu/corentic/springrag/agent/rag/support", + "method_count": 13, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.toDescriptor", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagAgentRegistry", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.Source", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/rag/support/src/test/kotlin/eu/corentic/springrag/agent/rag/support", + "method_count": 11, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagAgent", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationAuthorizer", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagAgentRegistry", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.Assertions.assertDoesNotThrow", + "import eu.corentic.springrag.model.PageTextElement", + "import eu.corentic.springrag.model.SourceImage", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.RetrievalPort", + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "agents/summarizer/embabel/src/main/kotlin/eu/corentic/springrag/agent/summarizer/embabel", + "method_count": 13, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.toDescriptor", + "import eu.corentic.springrag.agent.summarizer.SummarizerAgent", + "import eu.corentic.springrag.agent.summarizer.SummarizerAgentRegistry", + "import org.springframework.stereotype.Component", + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.Identities", + "import com.embabel.agent.core.ProcessOptions", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import eu.corentic.springrag.agent.summarizer.SummarizeRequest", + "import eu.corentic.springrag.agent.summarizer.SummaryResponse", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.Dispatchers", + "import kotlinx.coroutines.withContext", + "import org.springframework.stereotype.Service", + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.domain.io.UserInput", + "import com.embabel.common.ai.model.LlmOptions", + "import eu.corentic.springrag.agent.tooling.embabel.DEFAULT_TOOL_PROFILE", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationAction", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationRequest", + "import org.springframework.beans.factory.annotation.Value", + "import eu.corentic.springrag.agent.summarizer.SummarizerInvocationAuthorizer", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/summarizer/embabel/src/test/kotlin/eu/corentic/springrag/agent/summarizer/embabel", + "method_count": 14, + "imports": [ + "import com.embabel.agent.api.invocation.AgentInvocation", + "import com.embabel.agent.core.AgentPlatform", + "import com.embabel.agent.core.ProcessOptions", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.summarizer.SummarizeRequest", + "import eu.corentic.springrag.agent.summarizer.SummaryResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.mockkObject", + "import io.mockk.slot", + "import io.mockk.unmockkAll", + "import io.mockk.verify", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.summarizer.SummarizerAgent", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import eu.corentic.springrag.agent.summarizer.SummarizerInvocationAuthorizer", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import kotlinx.coroutines.test.runTest", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.Ai", + "import com.embabel.agent.api.common.PromptRunner", + "import com.embabel.common.ai.model.LlmOptions", + "import org.junit.jupiter.api.Assertions.assertDoesNotThrow" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/agent/src/main/kotlin/eu/corentic/springrag/agent/tooling/agent", + "method_count": 4, + "imports": [ + "import com.embabel.agent.api.annotation.AchievesGoal", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.annotation.Agent", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.domain.io.UserInput", + "import com.embabel.common.ai.model.LlmOptions", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationAction", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationRequest", + "import eu.corentic.springrag.agent.tooling.embabel.ToolInvocationResult", + "import org.springframework.stereotype.Service" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel", + "method_count": 12, + "imports": [ + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import com.embabel.agent.api.tool.ToolObject", + "import com.embabel.agent.api.annotation.Action", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.ContextualPromptElement", + "import com.embabel.common.ai.model.LlmOptions", + "import com.embabel.common.ai.prompt.PromptContributor", + "import com.embabel.agent.prompt.element.FocusedToolCallControl", + "import com.embabel.agent.prompt.element.ToolCallControl", + "import eu.corentic.springrag.agent.tooling.embabel.recording.ToolCallRecord", + "import eu.corentic.springrag.agent.tooling.embabel.recording.ToolInvocationRecorder", + "import org.springframework.stereotype.Service", + "import org.springframework.boot.context.properties.ConfigurationProperties", + "import org.springaicommunity.agent.tools.FileSystemTools", + "import org.springaicommunity.agent.tools.GrepTool", + "import org.springaicommunity.agent.tools.GlobTool", + "import org.springaicommunity.agent.tools.ShellTools", + "import org.springaicommunity.agent.tools.SmartWebFetchTool", + "import org.springframework.ai.chat.client.ChatClient", + "import org.springframework.boot.context.properties.EnableConfigurationProperties" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/embabel/src/main/kotlin/eu/corentic/springrag/agent/tooling/embabel/recording", + "method_count": 11, + "imports": [ + "import com.embabel.agent.api.event.AgentProcessEvent", + "import com.embabel.agent.api.event.AgenticEventListener", + "import com.embabel.agent.api.event.ToolCallResponseEvent", + "import com.fasterxml.jackson.core.JsonProcessingException", + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.slf4j.LoggerFactory", + "import java.util.concurrent.ConcurrentHashMap", + "import com.embabel.agent.api.common.PlatformServices", + "import com.embabel.agent.api.event.MulticastAgenticEventListener", + "import org.springframework.beans.factory.config.BeanPostProcessor", + "import org.springframework.boot.context.properties.EnableConfigurationProperties", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration" + ], + "arg_patterns": {} + }, + { + "label": "agents/tooling/embabel/src/test/kotlin/eu/corentic/springrag/agent/tooling/embabel", + "method_count": 6, + "imports": [ + "import com.embabel.agent.api.tool.ToolObject", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test", + "import com.embabel.agent.api.common.ActionContext", + "import com.embabel.agent.api.common.PromptRunner", + "import com.embabel.agent.core.Blackboard", + "import com.embabel.agent.core.ProcessContext", + "import io.mockk.Runs", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/adapters/src/main/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.toDescriptor", + "import org.springframework.stereotype.Component", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/adapters/src/test/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 8, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import io.mockk.every", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.Test", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.verify", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertDoesNotThrow" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/static/src/main/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.agent.capability.DescribedAgentCapability", + "import eu.corentic.springrag.agent.capability.TransportExposedAgentCapability", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "agents/wikipedia/static/src/test/kotlin/eu/corentic/springrag/agent/wikipedia", + "method_count": 3, + "imports": [ + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "app/src", + "method_count": 6, + "imports": [ + "import io.cucumber.spring.CucumberContextConfiguration", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Import", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.ApplicationArguments", + "import org.springframework.boot.ApplicationRunner", + "import org.springframework.core.env.ConfigurableEnvironment", + "import org.springframework.core.env.Environment", + "import org.springframework.core.env.EnumerablePropertySource", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import kotlin.test.assertEquals", + "import org.springframework.beans.factory.config.YamlPropertiesFactoryBean", + "import org.springframework.core.io.ClassPathResource" + ], + "arg_patterns": {} + }, + { + "label": "app/src/e2eTest/kotlin/eu/corentic/springrag/e2e/cucumber/steps", + "method_count": 17, + "algorithm": "CRX", + "grammar": "root ::= \"randomUUID\"?+ (\"File\" | \"absoluteFile\" | \"listOf\")?+ \"@\"? \"createKnowledgeBase\"? \"requireNotNull\"?+ (\"pollJobToCompletion\" | \"reset\")?+ \"toString\"?+ \"for\"? \"Suppress\"?+ \"currentTimeMillis\"?+ \"substring\"?+ \"if\"? \"registerUser\"? \"exists\"?+ \"login\"? \"return f\"? \"authToken\"? (\"APPLICATION_JSON\" | \"Any\" | \"MULTIPART_FORM_DATA\" | \"Map\" | \"MultipartBodyBuilder\" | \"String\" | \"assertNotNull\" | \"atMost\" | \"await\" | \"blockFirst\" | \"body\" | \"bodyValue\" | \"build\" | \"contentType\" | \"currentJobId\" | \"else\" | \"error\" | \"exchange\" | \"expectBody\" | \"expectStatus\" | \"findTestFile\" | \"fromMultipartData\" | \"get\" | \"header\" | \"isAccepted\" | \"isCreated\" | \"isOk\" | \"java\" | \"knowledgeBaseId\" | \"mapOf\" | \"name\" | \"ofMinutes\" | \"ofSeconds\" | \"part\" | \"pollInterval\" | \"post\" | \"readBytes\" | \"responseBody\" | \"return body ?: error(\\\"Create KB response body was null\\\")\" | \"return response?.get(\\\"answer\\\") as? String ?: \\\"\\\"\" | \"return response?.get(\\\"token\\\") as? String\n ?: error(\\\"Login response missing token\\\")\" | \"return@until false\" | \"returnResult\" | \"secondKnowledgeBaseId\" | \"status\" | \"until\" | \"uri\" | \"value\" | \"when\")?+ \"assertEquals\"? \"lastChatResponse\"? \"chat\"?", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.e2e.cucumber.config.ScenarioContext", + "import io.cucumber.java.en.Given", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.http.MediaType", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import java.util.UUID", + "import io.cucumber.java.en.Then", + "import io.cucumber.java.en.When", + "import io.cucumber.java.Before", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.web.reactive.function.BodyInserters", + "import java.io.File", + "import java.time.Duration" + ], + "arg_patterns": {} + }, + { + "label": "app/src/integrationTest/kotlin/eu/corentic/springrag/config", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= (\"ChatModel\" | \"Driver\" | \"QdrantClient\" | \"Session\" | \"String\" | \"also\" | \"any\" | \"close\" | \"every\" | \"mockk\" | \"run\" | \"session\")?+ \"return JobRepositoryTestUtils(jobRepository)\"? \"defaultOptions\"? \"JobRepositoryTestUtils\"? \"builder\"?+ \"build\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import org.springframework.batch.core.repository.JobRepository", + "import org.springframework.batch.test.JobRepositoryTestUtils", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.context.annotation.Bean", + "import ai.docling.serve.api.DoclingServeApi", + "import eu.corentic.springrag.agent.rag.embabel.EmbabelRagResponseInvoker", + "import eu.corentic.springrag.agent.summarizer.embabel.EmbabelSummarizerResponseInvoker", + "import com.embabel.agent.core.AgentPlatform", + "import io.mockk.mockk", + "import io.qdrant.client.QdrantClient", + "import org.neo4j.driver.Driver", + "import org.neo4j.driver.Session", + "import org.springframework.ai.chat.model.ChatModel", + "import org.springframework.ai.chat.prompt.ChatOptions", + "import org.springframework.ai.embedding.EmbeddingModel", + "import org.springframework.ai.vectorstore.VectorStore", + "import org.springframework.context.annotation.Primary", + "import org.springframework.security.authentication.ReactiveAuthenticationManager", + "import org.springframework.batch.core.launch.JobOperator" + ], + "arg_patterns": {} + }, + { + "label": "app/src/integrationTest/kotlin/eu/corentic/springrag/controller", + "method_count": 5, + "imports": [ + "import eu.corentic.springrag.config.IntegrationTestConfig", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.model.User", + "import eu.corentic.springrag.security.service.JwtService", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.BeforeEach", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.context.annotation.Import", + "import org.springframework.http.HttpHeaders", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import com.ninjasquad.springmockk.MockkBean", + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseService", + "import io.mockk.every", + "import java.io.ByteArrayInputStream", + "import org.springframework.core.io.InputStreamResource", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.MediaType", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.security.core.authority.SimpleGrantedAuthority", + "import org.springframework.web.reactive.function.BodyInserters", + "import org.springframework.boot.test.web.server.LocalServerPort" + ], + "arg_patterns": {} + }, + { + "label": "app/src/integrationTest/kotlin/eu/corentic/springrag/service", + "method_count": 3, + "imports": [ + "import com.ninjasquad.springmockk.MockkBean", + "import eu.corentic.springrag.config.IntegrationTestConfig", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import io.mockk.every", + "import java.util.UUID", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.context.annotation.Import", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.event.ApplicationEvents", + "import org.springframework.test.context.event.RecordApplicationEvents" + ], + "arg_patterns": {} + }, + { + "label": "app/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 14, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport.recreateTestCollection", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import io.qdrant.client.QdrantClient", + "import java.time.Duration", + "import java.time.Instant", + "import java.util.UUID", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.junit.jupiter.api.BeforeEach", + "import org.neo4j.driver.Driver", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.jdbc.core.JdbcTemplate", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.springframework.test.context.TestPropertySource", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.testcontainers.junit.jupiter.Testcontainers", + "import java.sql.Timestamp", + "import org.springframework.batch.core.repository.JobRepository", + "import org.springframework.batch.test.JobRepositoryTestUtils", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.context.annotation.Bean", + "import org.mockito.Mockito", + "import org.springframework.context.annotation.Primary" + ], + "arg_patterns": {} + }, + { + "label": "app/src/systemTest/kotlin/eu/corentic/springrag/system", + "method_count": 46, + "algorithm": "CRX", + "grammar": "root ::= \"queryForObject\"?+ \"session\"?+ \"MultipartBodyBuilder\"? (\"createKnowledgeBase\" | \"newClient\" | \"runBlocking\")?+ \"Long\"?+ \"use\"?+ \"part\"?+ \"run\"?+ \"readBytes\"?+ \"parameters\"?+ \"header\"?+ (\"COMPLETED\" | \"CallToolRequest\" | \"ClassPathResource\" | \"FAILED\" | \"IllegalStateException\" | \"JobStatus\" | \"List\" | \"MULTIPART_FORM_DATA\" | \"Map\" | \"McpSchema\" | \"PARTIAL_SUCCESS\" | \"String\" | \"TextContent\" | \"VectorChunk\" | \"absolutePath\" | \"add\" | \"adminClient\" | \"any\" | \"asJobId\" | \"assertEquals\" | \"assertNotEquals\" | \"assertNotNull\" | \"assertTrue\" | \"atMost\" | \"await\" | \"blockFirst\" | \"body\" | \"bodyValue\" | \"build\" | \"callTool\" | \"contains\" | \"content\" | \"contentType\" | \"copyTestDocument\" | \"count\" | \"countKnowledgeBaseNodes\" | \"countNodesByJobId\" | \"delete\" | \"documents\" | \"else\" | \"error\" | \"exchange\" | \"exists\" | \"expectBody\" | \"expectStatus\" | \"fail\" | \"fetchByJobId\" | \"file\" | \"filename\" | \"filter\" | \"first\" | \"fromMultipartData\" | \"get\" | \"getJobStatus\" | \"if\" | \"isAccepted\" | \"isCreated\" | \"isEmpty\" | \"isNoContent\" | \"isNotEmpty\" | \"isOk\" | \"java\" | \"length\" | \"listOf\" | \"map\" | \"mapNotNull\" | \"mapOf\" | \"metadata\" | \"mutate\" | \"name\" | \"ofMinutes\" | \"ofSeconds\" | \"path\" | \"pollInterval\" | \"post\" | \"queryParam\" | \"responseBody\" | \"responseTimeout\" | \"result\" | \"return response?.get(\\\"id\\\") as? String\n ?: error(\\\"Create knowledge base response missing id: $response\\\")\" | \"return response?.get(\\\"jobId\\\") as? String\n ?: error(\\\"Upload response missing jobId: $response\\\")\" | \"return terminalStatus ?: error(\\\"Job $jobId did not reach a terminal state in time\\\")\" | \"returnResult\" | \"searchSimilar\" | \"single\" | \"size\" | \"startJob\" | \"status\" | \"structuredContent\" | \"take\" | \"text\" | \"throw\" | \"try\" | \"until\" | \"uploadAsync\" | \"uploadAsyncMulti\" | \"uploadAsyncToKb\" | \"uri\" | \"value\" | \"waitForCompletedJob\" | \"waitForIndexedChunks\" | \"waitForTerminalStatus\" | \"waitUntil\" | \"when\")+ \"toPath\"?+ \"asLong\"?+ \"finally\"? \"resolve\"?+ \"closeGracefully\"?+ \"copy\"?+ \"REPLACE_EXISTING\"? \"return target.toFile()\"? \"toFile\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.controller.SessionChatRequest", + "import eu.corentic.springrag.model.ChatResponse", + "import java.time.Duration", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.test.web.reactive.server.returnResult", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.repository.VectorRepository", + "import eu.corentic.springrag.repository.graph.DocumentJobNodeRepository", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import java.io.File", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.nio.file.StandardCopyOption", + "import kotlin.io.path.createDirectory", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions.assertNotEquals", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.core.io.ClassPathResource", + "import org.springframework.http.MediaType", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.web.reactive.function.BodyInserters", + "import io.modelcontextprotocol.client.McpClient", + "import io.modelcontextprotocol.client.McpSyncClient", + "import io.modelcontextprotocol.client.transport.WebClientStreamableHttpTransport", + "import io.modelcontextprotocol.spec.McpSchema", + "import org.springframework.boot.test.web.server.LocalServerPort", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.web.reactive.function.client.WebClient", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotEquals", + "import kotlin.test.assertTrue", + "import org.neo4j.driver.Values", + "import eu.corentic.springrag.service.job.JobService", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.assertThrows", + "import java.util.*", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import java.util.stream.Stream", + "import org.awaitility.core.ConditionTimeoutException", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.params.ParameterizedTest", + "import org.junit.jupiter.params.provider.Arguments", + "import org.junit.jupiter.params.provider.MethodSource" + ], + "arg_patterns": {} + }, + { + "label": "app/src/test/kotlin/eu/corentic/springrag/architecture", + "method_count": 87, + "algorithm": "CRX", + "grammar": "root ::= \"scopeFromProject\"?+ (\"filesIn\" | \"productionClasses\")? \"classes\"?+ (\"Assertions\" | \"any\" | \"api\" | \"assertTrue\" | \"containingFile\" | \"contains\" | \"endsWith\" | \"exists\" | \"fileName\" | \"filter\" | \"filterNot\" | \"flatMap\" | \"forEach\" | \"functions\" | \"hasAnnotation\" | \"hasAnnotationWithName\" | \"hasImport\" | \"if\" | \"joinToString\" | \"junit\" | \"jupiter\" | \"listOf\" | \"name\" | \"parameters\" | \"path\" | \"productionFiles\" | \"readString\" | \"resideInPackage\" | \"resolve\" | \"startsWith\" | \"text\" | \"toString\")+", + "mdl_score": 1000000000000, + "imports": [ + "import java.nio.file.Files", + "import java.nio.file.Path", + "import kotlin.io.path.exists", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.fail", + "import com.lemonappdev.konsist.api.Konsist", + "import com.lemonappdev.konsist.api.ext.list.withAnnotationOf", + "import com.lemonappdev.konsist.api.verify.assertTrue", + "import org.springframework.stereotype.Service", + "import java.io.IOException", + "import java.nio.file.FileVisitResult", + "import java.nio.file.Paths", + "import java.nio.file.SimpleFileVisitor", + "import java.nio.file.attribute.BasicFileAttributes" + ], + "arg_patterns": {} + }, + { + "label": "app/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "imports": [ + "import kotlin.test.assertEquals", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.config.YamlPropertiesFactoryBean", + "import org.springframework.core.io.ClassPathResource" + ], + "arg_patterns": {} + }, + { + "label": "buildSrc/src/main/kotlin", + "method_count": 8, + "imports": [ + "import org.gradle.api.Project", + "import org.gradle.api.artifacts.VersionCatalogsExtension", + "import org.gradle.api.file.SourceDirectorySet", + "import org.gradle.api.plugins.JavaPluginExtension", + "import org.gradle.api.tasks.SourceSet", + "import org.gradle.api.tasks.SourceSetContainer", + "import org.gradle.api.tasks.TaskProvider", + "import org.gradle.api.tasks.testing.Test", + "import org.gradle.jvm.toolchain.JavaLanguageVersion", + "import org.gradle.kotlin.dsl.get", + "import org.gradle.kotlin.dsl.getByType", + "import org.gradle.kotlin.dsl.named", + "import org.gradle.kotlin.dsl.register", + "import org.gradle.kotlin.dsl.withType" + ], + "arg_patterns": {} + }, + { + "label": "buildSrc/src/test/kotlin", + "method_count": 5, + "imports": [ + "import java.net.URI", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFalse", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import org.gradle.api.artifacts.repositories.MavenArtifactRepository", + "import org.gradle.api.tasks.SourceSetContainer", + "import org.gradle.testfixtures.ProjectBuilder", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/agent-mcp-server/src/main/kotlin/eu/corentic/springrag/mcp", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.isExposedOverMcp", + "import io.modelcontextprotocol.spec.McpSchema.CallToolResult", + "import kotlinx.coroutines.reactor.mono", + "import org.springaicommunity.mcp.annotation.McpTool", + "import org.springframework.stereotype.Component", + "import reactor.core.publisher.Mono", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.toMarkdownSummary", + "import org.springaicommunity.mcp.annotation.McpToolParam", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupInvocationGateway", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupRequest" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/agent-mcp-server/src/test/kotlin/eu/corentic/springrag/mcp", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.modelcontextprotocol.spec.McpSchema.TextContent", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.model.Source", + "import io.mockk.coEvery", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupInvocationGateway", + "import eu.corentic.springrag.agent.wikipedia.WikipediaLookupResponse" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "imports": [ + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.web.reactive.config.CorsRegistry", + "import org.springframework.web.reactive.config.WebFluxConfigurer", + "import org.slf4j.MDC", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.web.server.ServerWebExchange", + "import org.springframework.web.server.WebFilter", + "import org.springframework.web.server.WebFilterChain", + "import reactor.core.publisher.Mono", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.core.Ordered", + "import org.springframework.core.annotation.Order", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller", + "method_count": 58, + "algorithm": "CRX", + "grammar": "root ::= \"return ResponseEntity.noContent().build()\"? \"bindingResult\"? \"getJobStatus\"?+ (\"mutableListOf\" | \"return ResponseEntity.ok(response)\")?+ \"noContent\"?+ \"fieldErrors\"? \"return if (status != null) {\n ResponseEntity.ok(status)\n } else {\n ResponseEntity.notFound().build()\n }\"? \"joinToString\"?+ \"field\"? \"defaultMessage\"? (\"BAD_REQUEST\" | \"CONFLICT\" | \"CREATED\" | \"DataBuffer\" | \"ErrorResponse\" | \"InvalidUploadRequestException\" | \"KnowledgeBaseNotFoundException\" | \"NOT_FOUND\" | \"PAYLOAD_TOO_LARGE\" | \"RuntimeException\" | \"TimeoutCancellationException\" | \"accepted\" | \"add\" | \"agentId\" | \"batchUploadRoot\" | \"body\" | \"buffer\" | \"catch\" | \"cleanupManagedUpload\" | \"content\" | \"conversationId\" | \"core\" | \"else\" | \"error\" | \"errorCode\" | \"filename\" | \"handle\" | \"headers\" | \"if\" | \"io\" | \"knowledgeBaseExists\" | \"knowledgeBaseId\" | \"map\" | \"mapOf\" | \"maxFileError\" | \"maxUploadBytes\" | \"message\" | \"name\" | \"next\" | \"of\" | \"ok\" | \"password\" | \"randomUUID\" | \"readableByteCount\" | \"registerBatch\" | \"release\" | \"return ResponseEntity.status(HttpStatus.BAD_REQUEST)\n .body(ErrorResponse(\\\"VALIDATION_ERROR\\\", \\\"Validation failed\\\", errors))\" | \"size\" | \"springframework\" | \"startBulkJob\" | \"startJob\" | \"status\" | \"throw\" | \"throw KnowledgeBaseNotFoundException(knowledgeBaseId)\" | \"throw e\" | \"toString\" | \"try\" | \"username\" | \"value\" | \"warn\" | \"withTimeout\")?+ \"let\"?+ \"ChatResponse\"? \"notFound\"?+ \"write\"?+ \"emptyList\"?+ \"build\"?+ \"then\"?+ \"awaitSingleOrNull\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.job.BatchOwnershipService", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseNotFoundException", + "import jakarta.validation.constraints.NotBlank", + "import jakarta.validation.constraints.Pattern", + "import org.springframework.http.ResponseEntity", + "import org.springframework.security.access.prepost.PreAuthorize", + "import org.springframework.security.core.Authentication", + "import org.springframework.validation.annotation.Validated", + "import org.springframework.web.bind.annotation.*", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.service.chat.ChatService", + "import jakarta.validation.Valid", + "import org.springframework.web.bind.annotation.GetMapping", + "import org.springframework.web.bind.annotation.PostMapping", + "import org.springframework.web.bind.annotation.RequestBody", + "import org.springframework.web.bind.annotation.RequestMapping", + "import org.springframework.web.bind.annotation.RestController", + "import kotlinx.coroutines.TimeoutCancellationException", + "import kotlinx.coroutines.withTimeout", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.beans.factory.annotation.Value", + "import java.util.UUID", + "import eu.corentic.springrag.controller.dto.ErrorResponse", + "import eu.corentic.springrag.security.service.PasswordPolicyViolationException", + "import eu.corentic.springrag.security.service.UserAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.DocumentNotFoundInKnowledgeBaseException", + "import eu.corentic.springrag.service.knowledgebase.InvalidKnowledgeBaseNameException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseSizeLimitExceededException", + "import eu.corentic.springrag.service.job.JobAlreadyCompleteException", + "import eu.corentic.springrag.service.job.JobAlreadyRunningException", + "import eu.corentic.springrag.service.job.JobExecutionNotFoundException", + "import eu.corentic.springrag.service.job.BatchOwnershipException", + "import eu.corentic.springrag.service.job.BatchNotFoundException", + "import eu.corentic.springrag.service.job.BatchOwnerRequiredException", + "import eu.corentic.springrag.service.job.JobInputValidationException", + "import jakarta.validation.ConstraintViolationException", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.converter.HttpMessageNotReadableException", + "import org.springframework.core.io.buffer.DataBufferLimitException", + "import org.springframework.web.bind.MethodArgumentNotValidException", + "import org.springframework.web.bind.annotation.ExceptionHandler", + "import org.springframework.web.bind.annotation.RestControllerAdvice", + "import org.springframework.web.method.annotation.MethodArgumentTypeMismatchException", + "import org.springframework.web.server.ServerWebInputException", + "import org.springframework.web.server.MissingRequestValueException", + "import org.springframework.web.bind.support.WebExchangeBindException", + "import eu.corentic.springrag.service.knowledgebase.*", + "import io.swagger.v3.oas.annotations.Operation", + "import io.swagger.v3.oas.annotations.tags.Tag", + "import io.swagger.v3.oas.annotations.Parameter", + "import java.security.Principal", + "import kotlinx.coroutines.reactor.awaitSingle", + "import org.springframework.http.codec.multipart.FilePart", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import kotlinx.coroutines.reactor.awaitSingleOrNull", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import org.springframework.core.io.buffer.DataBufferUtils", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.security.service.JwtService", + "import eu.corentic.springrag.security.service.UserService", + "import org.springframework.security.crypto.password.PasswordEncoder" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/librechat", + "method_count": 29, + "imports": [ + "import com.fasterxml.jackson.annotation.JsonProperty", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.service.document.DocumentIdentity", + "import eu.corentic.springrag.service.port.DocumentIdPort", + "import eu.corentic.springrag.service.port.DocumentImagePort", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.service.port.VectorDocumentDeletionPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalInvoker", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.port.AgentKnowledgeBasePort", + "import jakarta.validation.Valid", + "import jakarta.validation.constraints.NotBlank", + "import jakarta.validation.constraints.NotEmpty", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.withContext", + "import kotlinx.coroutines.reactor.awaitSingleOrNull", + "import org.springframework.http.MediaType", + "import org.springframework.http.ResponseEntity", + "import org.springframework.http.codec.multipart.FilePart", + "import org.springframework.web.bind.annotation.*", + "import org.springframework.core.io.buffer.DataBufferUtils", + "import kotlin.math.max", + "import kotlin.math.min", + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.controller.InvalidUploadRequestException", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.util.UUID", + "import kotlin.time.Duration.Companion.seconds", + "import kotlinx.coroutines.delay", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/main/kotlin/eu/corentic/springrag/controller/web", + "method_count": 6, + "imports": [ + "import eu.corentic.springrag.controller.UploadWorkflow", + "import eu.corentic.springrag.controller.InvalidUploadRequestException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseNotFoundException", + "import java.security.Principal", + "import kotlinx.coroutines.reactor.awaitSingle", + "import org.springframework.http.MediaType", + "import org.springframework.http.ResponseEntity", + "import org.springframework.http.codec.multipart.FilePart", + "import org.springframework.stereotype.Controller", + "import org.springframework.web.bind.annotation.PostMapping", + "import org.springframework.web.bind.annotation.RequestParam", + "import org.springframework.web.bind.annotation.RequestPart", + "import org.springframework.web.bind.annotation.ResponseBody", + "import reactor.core.publisher.Flux", + "import org.springframework.web.bind.annotation.GetMapping" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"webTestClient\"? \"from\"?+ \"bindToWebHandler\"?+ \"post\"?+ \"WebHandler\"? (\"OK\" | \"response\" | \"setStatusCode\")?+ \"setComplete\"?+ \"webFilter\"?+ \"build\"?+ (\"AtomicReference\" | \"String\")?+ \"WebFilterChain\"? (\"assertEquals\" | \"assertNull\" | \"block\" | \"empty\" | \"filter\" | \"get\" | \"set\")?+ \"uri\"?+ \"exchange\"?+ \"expectStatus\"?+ \"isOk\"?", + "mdl_score": 1000000000000, + "imports": [ + "import java.util.concurrent.atomic.AtomicReference", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import org.slf4j.MDC", + "import org.springframework.mock.http.server.reactive.MockServerHttpRequest", + "import org.springframework.mock.web.server.MockServerWebExchange", + "import org.springframework.web.server.WebFilterChain", + "import reactor.core.publisher.Mono", + "import org.springframework.http.HttpStatus", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.web.server.WebHandler" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller", + "method_count": 83, + "algorithm": "CRX", + "grammar": "root ::= \"runTest\"? (\"BAD_REQUEST\" | \"COMPLETED\" | \"ChatRequest\" | \"ChatResponse\" | \"GlobalExceptionHandler\" | \"JobStatus\" | \"MULTIPART_FORM_DATA\" | \"MultipartBodyBuilder\" | \"NOT_FOUND\" | \"SessionChatRequest\" | \"StorageProperties\" | \"String\" | \"any\" | \"assertEquals\" | \"bindToController\" | \"body\" | \"bodyValue\" | \"build\" | \"chatWithSources\" | \"chatWithSourcesAndMemory\" | \"coEvery\" | \"contentType\" | \"controllerAdvice\" | \"emptyList\" | \"every\" | \"exchange\" | \"expectBody\" | \"expectStatus\" | \"fromMultipartData\" | \"get\" | \"getJobStatus\" | \"header\" | \"isAccepted\" | \"isBadRequest\" | \"isEqualTo\" | \"isNotFound\" | \"isOk\" | \"jsonPath\" | \"knowledgeBaseExists\" | \"listOf\" | \"minusMinutes\" | \"mockk\" | \"now\" | \"part\" | \"post\" | \"runBlocking\" | \"startBulkJob\" | \"statusCode\" | \"toByteArray\" | \"toString\" | \"uri\" | \"value\" | \"verify\")+ \"error\"?", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.job.BatchOwnershipService", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.BatchOwnershipException", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.nio.file.Path", + "import java.time.Duration", + "import java.time.LocalDateTime", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import eu.corentic.springrag.service.job.BatchNotFoundException", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.model.Source", + "import eu.corentic.springrag.service.chat.ChatService", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import kotlinx.coroutines.test.runTest", + "import org.springframework.http.codec.json.JacksonJsonDecoder", + "import org.springframework.http.codec.json.JacksonJsonEncoder", + "import tools.jackson.databind.json.JsonMapper", + "import tools.jackson.module.kotlin.KotlinModule", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import eu.corentic.springrag.security.service.PasswordPolicyViolationException", + "import eu.corentic.springrag.security.service.UserAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.DocumentNotFoundInKnowledgeBaseException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseAlreadyExistsException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseSizeLimitExceededException", + "import eu.corentic.springrag.service.knowledgebase.InvalidKnowledgeBaseNameException", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseNotFoundException", + "import eu.corentic.springrag.service.job.JobAlreadyCompleteException", + "import eu.corentic.springrag.service.job.BatchOwnerRequiredException", + "import eu.corentic.springrag.service.job.JobAlreadyRunningException", + "import eu.corentic.springrag.service.job.JobExecutionNotFoundException", + "import eu.corentic.springrag.service.job.JobInputValidationException", + "import java.io.ByteArrayInputStream", + "import kotlin.test.assertEquals", + "import org.springframework.core.io.buffer.DataBufferLimitException", + "import org.springframework.core.MethodParameter", + "import org.springframework.http.HttpHeaders", + "import org.springframework.http.HttpInputMessage", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.converter.HttpMessageNotReadableException", + "import org.springframework.web.method.annotation.MethodArgumentTypeMismatchException", + "import eu.corentic.springrag.service.knowledgebase.CreateKnowledgeBaseRequest", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseListItem", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseStatistics", + "import io.mockk.just", + "import io.mockk.runs", + "import java.time.Instant", + "import kotlinx.coroutines.runBlocking", + "import org.springframework.http.MediaType", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.mockk.slot", + "import java.io.File", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.web.reactive.function.BodyInserters" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/auth", + "method_count": 5, + "imports": [ + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.model.User", + "import eu.corentic.springrag.security.service.JwtService", + "import eu.corentic.springrag.security.service.UserAlreadyExistsException", + "import eu.corentic.springrag.security.service.UserService", + "import io.mockk.MockKAnnotations", + "import io.mockk.every", + "import io.mockk.impl.annotations.MockK", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.assertThrows", + "import org.springframework.http.HttpStatus", + "import org.springframework.security.crypto.password.PasswordEncoder" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/librechat", + "method_count": 46, + "algorithm": "CRX", + "grammar": "root ::= \"coEvery\"? \"runTest\"? \"mockk\"? \"mockFilePart\"? \"FilePart\"? (\"APPLICATION_JSON\" | \"APPLICATION_PDF\" | \"COMPLETED\" | \"DocumentImageInfo\" | \"EmbedOutcome\" | \"FAILED\" | \"GraphDocument\" | \"InvalidUploadRequestException\" | \"JobStatus\" | \"LibreChatRagIngestionService\" | \"LibreChatRetrievalRequest\" | \"LibreChatRetrievalResult\" | \"MULTIPART_FORM_DATA\" | \"MultipartBodyBuilder\" | \"ParsedDocument\" | \"RuntimeException\" | \"String\" | \"VectorChunk\" | \"any\" | \"asStorageUri\" | \"assertEquals\" | \"assertFailsWith\" | \"assertNotNull\" | \"batchUploadFile\" | \"batchUploadRoot\" | \"body\" | \"bodyValue\" | \"build\" | \"capture\" | \"captured\" | \"coVerify\" | \"contentType\" | \"emptyList\" | \"emptyMap\" | \"every\" | \"exchange\" | \"expectBody\" | \"expectStatus\" | \"fetchByJobId\" | \"fileId\" | \"fileIds\" | \"filename\" | \"findPageRendering\" | \"fromMultipartData\" | \"get\" | \"getJobStatus\" | \"getOrCreateAgentKnowledgeBase\" | \"header\" | \"ingestLocalFile\" | \"ingestMultipart\" | \"invoke\" | \"isEqualTo\" | \"isObjectStorageRoot\" | \"isOk\" | \"java\" | \"jsonPath\" | \"knowledgeBaseId\" | \"listOf\" | \"loadImage\" | \"mapOf\" | \"of\" | \"parse\" | \"part\" | \"post\" | \"slot\" | \"startJobWithId\" | \"toByteArray\" | \"uri\" | \"value\" | \"verify\")+ (\"assertContains\" | \"message\")?+ (\"assertTrue\" | \"doesNotExist\" | \"isNotFound\")?+", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalInvoker", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalRequest", + "import eu.corentic.springrag.agent.rag.librechat.LibreChatRetrievalResult", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.controller.GlobalExceptionHandler", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.JobStatus", + "import eu.corentic.springrag.service.job.JobStatusType", + "import eu.corentic.springrag.service.port.AgentKnowledgeBasePort", + "import eu.corentic.springrag.service.port.DocumentIdPort", + "import eu.corentic.springrag.service.port.DocumentImageInfo", + "import eu.corentic.springrag.service.port.DocumentImagePort", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.service.port.VectorDocumentDeletionPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import kotlinx.coroutines.CoroutineDispatcher", + "import kotlinx.coroutines.test.UnconfinedTestDispatcher", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.http.HttpMethod", + "import org.springframework.http.MediaType", + "import org.springframework.http.client.MultipartBodyBuilder", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.web.reactive.function.BodyInserters", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.controller.InvalidUploadRequestException", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import kotlinx.coroutines.test.runTest", + "import org.springframework.core.io.buffer.DefaultDataBufferFactory", + "import org.springframework.http.HttpHeaders", + "import org.springframework.http.codec.multipart.FilePart", + "import reactor.core.publisher.Flux", + "import kotlin.test.assertContains", + "import kotlin.test.assertFailsWith" + ], + "arg_patterns": {} + }, + { + "label": "entrypoints/web/src/test/kotlin/eu/corentic/springrag/controller/web", + "method_count": 10, + "imports": [ + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.controller.UploadWorkflow", + "import eu.corentic.springrag.service.job.BatchOwnershipService", + "import eu.corentic.springrag.service.job.JobService", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseApplicationService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.service.knowledgebase.KnowledgeBaseResponse", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.time.Duration", + "import java.time.Instant", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.http.HttpHeaders", + "import org.springframework.http.HttpStatus", + "import org.springframework.http.codec.multipart.FilePart", + "import reactor.core.publisher.Flux", + "import reactor.core.publisher.Mono" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters", + "method_count": 3, + "imports": [ + "import org.springframework.ai.chat.memory.ChatMemory", + "import org.springframework.ai.chat.memory.ChatMemoryRepository", + "import org.springframework.ai.chat.memory.MessageWindowChatMemory", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.neo4j.driver.Driver", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.context.annotation.Primary", + "import org.springframework.data.neo4j.core.transaction.Neo4jTransactionManager", + "import org.springframework.transaction.PlatformTransactionManager", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.CommandLineRunner" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 4, + "imports": [ + "import io.netty.channel.ChannelOption", + "import io.netty.handler.timeout.ReadTimeoutHandler", + "import io.netty.handler.timeout.WriteTimeoutHandler", + "import java.util.concurrent.TimeUnit", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.http.client.ClientHttpRequestFactory", + "import org.springframework.http.client.ReactorClientHttpRequestFactory", + "import reactor.netty.http.client.HttpClient", + "import com.fasterxml.jackson.databind.ObjectMapper", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingModel", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingOptions", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingRequest", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingResponse", + "import org.springframework.ai.embedding.EmbeddingModel", + "import org.springframework.beans.factory.annotation.Qualifier", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.context.annotation.Primary", + "import software.amazon.awssdk.auth.credentials.AwsCredentialsProvider", + "import software.amazon.awssdk.regions.providers.AwsRegionProvider", + "import java.time.Duration", + "import org.springframework.ai.ollama.api.OllamaApi", + "import org.springframework.context.annotation.Profile", + "import org.springframework.web.client.RestClient" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/main/kotlin/eu/corentic/springrag/health", + "method_count": 3, + "imports": [ + "import org.springframework.ai.ollama.api.OllamaApi", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.boot.health.contributor.Health", + "import org.springframework.boot.health.contributor.ReactiveHealthIndicator", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.context.annotation.Profile", + "import org.springframework.stereotype.Component", + "import java.util.function.Supplier", + "import reactor.core.publisher.Mono", + "import reactor.core.scheduler.Schedulers" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"assertThrows\"? \"IllegalArgumentException\"? \"java\"? \"EmbabelAiHttpClientProperties\"? \"OllamaClientProperties\"? \"Timeout\"?+ (\"assertEquals\" | \"baseUrl\" | \"ofSeconds\" | \"readTimeout\" | \"writeTimeout\")+ \"timeout\"? \"connectTimeout\"? \"read\"?", + "mdl_score": 1313088395, + "imports": [ + "import java.time.Duration", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/health", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"`when`\" \"listModels\"+ \"thenReturn\"?+ \"thenThrow\"?+ \"ListModelResponse\"?+ \"RuntimeException\"? \"listOf\"?+ (\"Model\" | \"now\")?+ \"requireNotNull\"+ \"OllamaHealthIndicator\" \"NoOpCircuitBreakerFactory\" \"health\"+ \"block\"+ \"assertEquals\" \"status\" \"code\"", + "mdl_score": 11495462, + "imports": [ + "import java.time.Instant", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.`when`", + "import org.springframework.ai.ollama.api.OllamaApi" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/service/embedding", + "method_count": 5, + "imports": [ + "import com.fasterxml.jackson.databind.ObjectMapper", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingModel", + "import org.springframework.ai.bedrock.cohere.BedrockCohereEmbeddingOptions", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingRequest", + "import org.springframework.ai.bedrock.cohere.api.CohereEmbeddingBedrockApi.CohereEmbeddingResponse", + "import org.springframework.ai.embedding.EmbeddingRequest", + "import software.amazon.awssdk.auth.credentials.AnonymousCredentialsProvider", + "import software.amazon.awssdk.regions.Region", + "import java.time.Duration" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/ai-provider/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/chat-memory/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 6, + "imports": [ + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.chat.memory.InMemoryChatMemoryRepository", + "import org.springframework.ai.chat.messages.Message", + "import org.springframework.ai.chat.messages.MessageType" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src", + "method_count": 6, + "imports": [ + "import ai.docling.serve.api.DoclingServeApi", + "import org.springframework.boot.health.contributor.Health", + "import org.springframework.boot.health.contributor.ReactiveHealthIndicator", + "import org.springframework.stereotype.Component", + "import reactor.core.publisher.Mono", + "import reactor.core.scheduler.Schedulers", + "import eu.corentic.springrag.service.docling.DoclingGraphDocumentMapper", + "import eu.corentic.springrag.service.docling.DoclingService", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.config.DoclingConfig", + "import java.io.File", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.core.io.ClassPathResource", + "import org.springframework.test.context.TestPropertySource", + "import ai.docling.core.DoclingDocument", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.every", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "imports": [ + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.client.DoclingServeJackson3Client", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import java.lang.reflect.Method", + "import java.net.URI", + "import java.time.Duration", + "import jakarta.validation.constraints.Min", + "import jakarta.validation.constraints.NotBlank", + "import jakarta.annotation.PostConstruct", + "import org.slf4j.LoggerFactory", + "import org.springframework.boot.context.properties.ConfigurationProperties", + "import org.springframework.validation.annotation.Validated" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/main/kotlin/eu/corentic/springrag/service/docling", + "method_count": 21, + "imports": [ + "import com.google.auth.oauth2.GoogleCredentials", + "import com.google.auth.oauth2.IdTokenCredentials", + "import com.google.auth.oauth2.IdTokenProvider", + "import ai.docling.core.DoclingDocument", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphImagePayload", + "import eu.corentic.springrag.model.GraphPage", + "import eu.corentic.springrag.model.GraphPictureElement", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Component", + "import java.util.Base64", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.api.convert.request.options.ConvertDocumentOptions", + "import ai.docling.serve.api.convert.request.options.ImageRefMode", + "import ai.docling.serve.api.convert.request.options.OcrEngine", + "import ai.docling.serve.api.convert.request.options.PdfBackend", + "import ai.docling.serve.api.convert.request.options.ProcessingPipeline", + "import ai.docling.serve.api.convert.request.options.OutputFormat", + "import ai.docling.serve.api.convert.request.source.FileSource", + "import ai.docling.serve.api.convert.request.target.InBodyTarget", + "import ai.docling.serve.api.convert.request.target.S3Target", + "import eu.corentic.springrag.config.DoclingConfig", + "import java.util.function.Supplier", + "import java.time.Duration", + "import jakarta.annotation.PostConstruct", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.stereotype.Service" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 6, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.testcontainers.junit.jupiter.Testcontainers", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.client.DoclingServeClientBuilderFactory", + "import java.lang.reflect.InvocationTargetException", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= \"PipelineOptions\"? \"DoclingConfig\"? \"doclingServeApi\"?+ \"trimIndent\"?+ (\"assertNull\" | \"concurrency\" | \"layoutBatchSize\" | \"ocrBatchSize\" | \"tableBatchSize\")?+ \"baseUrl\"? \"assertNotNull\"?+ \"lines\"?+ \"documentTimeout\"? (\"imageExportMode\" | \"includeImages\" | \"options\" | \"useS3Target\")?+ \"toString\"?+ (\"indexOfFirst\" | \"startsWith\" | \"trimStart\")?+ \"s3Target\"? (\"assertThat\" | \"contains\" | \"doesNotContain\" | \"isGreaterThan\")?+ \"bucket\"? \"assertThatThrownBy\"? \"validateCriticalSettings\"?+ \"isInstanceOf\"?+ \"IllegalStateException\"? \"java\"? \"hasMessageContaining\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.Test", + "import org.assertj.core.api.Assertions.assertThat", + "import org.assertj.core.api.Assertions.assertThatThrownBy", + "import org.junit.jupiter.api.Assertions.assertNull" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/health", + "method_count": 3, + "imports": [ + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.api.health.HealthCheckResponse", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.`when`" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/service/docling", + "method_count": 10, + "imports": [ + "import ai.docling.core.DoclingDocument", + "import eu.corentic.springrag.common.ids.asJobId", + "import java.util.Base64", + "import org.junit.jupiter.api.Assertions.assertArrayEquals", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.api.convert.request.ConvertDocumentRequest", + "import ai.docling.serve.api.convert.request.options.ImageRefMode", + "import ai.docling.serve.api.convert.request.options.OcrEngine", + "import ai.docling.serve.api.convert.request.options.OutputFormat", + "import ai.docling.serve.api.convert.request.options.PdfBackend", + "import ai.docling.serve.api.convert.request.options.ProcessingPipeline", + "import ai.docling.serve.api.convert.response.InBodyConvertDocumentResponse", + "import ai.docling.serve.api.convert.response.DocumentResponse", + "import eu.corentic.springrag.config.DoclingConfig", + "import eu.corentic.springrag.config.PipelineOptions", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import io.mockk.clearAllMocks", + "import tools.jackson.databind.ObjectMapper", + "import ai.docling.serve.api.convert.request.target.S3Target", + "import ai.docling.serve.api.convert.request.target.InBodyTarget", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.slot", + "import io.mockk.verify", + "import java.util.concurrent.CompletableFuture", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.assertThrows" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/doc-parser/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/health", + "method_count": 7, + "imports": [ + "import org.neo4j.driver.Driver", + "import java.time.Duration", + "import org.springframework.boot.health.contributor.Health", + "import org.springframework.boot.health.contributor.ReactiveHealthIndicator", + "import org.springframework.stereotype.Component", + "import reactor.core.publisher.Mono", + "import com.google.common.util.concurrent.FutureCallback", + "import com.google.common.util.concurrent.Futures", + "import com.google.common.util.concurrent.ListenableFuture", + "import com.google.common.util.concurrent.MoreExecutors", + "import io.qdrant.client.QdrantClient", + "import java.util.concurrent.ExecutionException", + "import java.util.concurrent.TimeoutException", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Profile" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/model/graph", + "method_count": 9, + "imports": [ + "import java.time.Instant", + "import org.springframework.data.annotation.Version", + "import org.springframework.data.neo4j.core.schema.Id", + "import org.springframework.data.neo4j.core.schema.Node", + "import org.springframework.data.neo4j.core.schema.Relationship", + "import org.springframework.data.neo4j.core.schema.Property" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/repository", + "method_count": 24, + "algorithm": "CRX", + "grammar": "root ::= \"run\"?+ \"replace\"?+ \"debug\"?+ \"mutableListOf\"?+ \"VectorChunk\"? \"Document\"? \"Supplier\"? \"String\"?+ \"toMap\"?+ \"orEmpty\"?+ \"action\"? (\"add\" | \"build\" | \"builder\" | \"deleteByFilter\" | \"distinct\" | \"emptyList\" | \"escapeFilterValue\" | \"filterEquals\" | \"filterExpression\" | \"if\" | \"isEmpty\" | \"isNotEmpty\" | \"isNullOrEmpty\" | \"joinToString\" | \"query\" | \"return\" | \"return emptyList()\" | \"return runWithCircuitBreaker { vectorStore.similaritySearch(request).map { it.toVectorChunk() } }\" | \"runWithCircuitBreaker\" | \"size\" | \"topK\" | \"value\")?+ \"toMutableMap\"?+ \"IllegalStateException\"? \"delete\"?+ \"similaritySearch\"?+ \"apply\"?+ \"warn\"?+ \"map\"?+ \"putIfAbsent\"? \"message\"? (\"toSpringDocument\" | \"toVectorChunk\")?+ \"throw cause\"? \"throw\"?", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.model.VectorChunk", + "import org.springframework.ai.document.Document", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import java.util.function.Supplier", + "import org.springframework.ai.vectorstore.SearchRequest", + "import org.springframework.ai.vectorstore.VectorStore", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Repository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/agent", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.model.graph.AgentNode", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.repository.graph.AgentRepository", + "import eu.corentic.springrag.repository.graph.KnowledgeBaseRepository", + "import eu.corentic.springrag.service.port.AgentKnowledgeBasePort", + "import org.springframework.stereotype.Service", + "import org.springframework.transaction.annotation.Transactional", + "import java.time.Instant" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/cleanup", + "method_count": 4, + "algorithm": "CRX", + "grammar": "root ::= \"info\"+ (\"deleteByJobId\" | \"deleteByKnowledgeBaseId\" | \"jobId\" | \"knowledgeBaseId\" | \"value\")+", + "mdl_score": 1015620, + "imports": [ + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.service.graph.GraphIngestionOrchestrator", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.modulith.events.ApplicationModuleListener", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.repository.VectorRepository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/graph", + "method_count": 12, + "imports": [ + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphImagePayload", + "import eu.corentic.springrag.model.GraphPictureElement", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.model.graph.ImageData", + "import eu.corentic.springrag.model.graph.PageNode", + "import eu.corentic.springrag.model.graph.PictureElement", + "import eu.corentic.springrag.model.graph.TableElement", + "import eu.corentic.springrag.model.graph.TextElement", + "import eu.corentic.springrag.service.port.DocumentGraphJobPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import java.util.function.Supplier", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.stereotype.Component", + "import org.springframework.transaction.annotation.Propagation", + "import org.springframework.transaction.annotation.Transactional", + "import java.time.Instant", + "import java.util.concurrent.CompletableFuture", + "import java.util.concurrent.Executors" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/port/adapter", + "method_count": 45, + "algorithm": "CRX", + "grammar": "root ::= (\"Regex\" | \"emptyList\" | \"if\" | \"isNullOrBlank\" | \"replace\" | \"return emptyList()\")?+ \"deleteByJobId\"?+ \"save\"?+ \"of\"?+ \"findById\"?+ \"toNode\"?+ \"value\"?+ \"map\"?+ \"orElse\"?+ \"toDomain\"?+ \"text\"? \"let\"?+ \"storageUri\"? (\"imageType\" | \"pageNo\")?+", + "mdl_score": 41773224, + "imports": [ + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.model.PageTextElement", + "import eu.corentic.springrag.model.SourceImage", + "import eu.corentic.springrag.repository.graph.ImageDataRepository", + "import eu.corentic.springrag.repository.graph.TextElementRepository", + "import eu.corentic.springrag.repository.graph.TableElementRepository", + "import eu.corentic.springrag.service.port.ChatGraphLookupPort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import java.util.Base64", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.repository.graph.DocumentJobNodeRepository", + "import eu.corentic.springrag.service.port.DocumentGraphJobPort", + "import java.time.Instant", + "import eu.corentic.springrag.service.port.DocumentIdPort", + "import eu.corentic.springrag.service.port.DocumentImageInfo", + "import eu.corentic.springrag.service.port.DocumentImagePort", + "import eu.corentic.springrag.repository.graph.GraphMaintenanceRepository", + "import eu.corentic.springrag.service.graph.GraphDeletePort", + "import eu.corentic.springrag.service.graph.GraphStorePort", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import eu.corentic.springrag.model.KnowledgeBase", + "import eu.corentic.springrag.model.KnowledgeBaseStats", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.repository.graph.KnowledgeBaseRepository", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import eu.corentic.springrag.service.port.VectorDocumentDeletionPort", + "import eu.corentic.springrag.service.port.VectorDocumentPort", + "import eu.corentic.springrag.service.port.RetrievalPort" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/main/kotlin/eu/corentic/springrag/service/storage", + "method_count": 40, + "algorithm": "CRX", + "grammar": "root ::= \"loadObject\"? \"replace\"?+ \"buildImageKey\"? \"when\"? (\"listObjects\" | \"return parseStorageUri(storageUri)\n ?: S3Location(bucket = properties.bucket, key = storageUri.trimStart('/'))\")? \"ifBlank\"?+ \"return storeObject(key, bytes, contentTypeFor(format))\"? \"lowercase\"?+ \"storeObject\"? \"return StorageUri.of(\\\"images/${jobId.value}/$sanitizedId.$extension\\\")\"? \"contentTypeFor\"? (\"BlobListOption\" | \"GcsLocation\" | \"NoSuchBucketException\" | \"ObjectIdentifier\" | \"S3Exception\" | \"S3Location\" | \"amazon\" | \"awssdk\" | \"bucket\" | \"build\" | \"builder\" | \"catch\" | \"chunked\" | \"contentType\" | \"contents\" | \"create\" | \"credentialsProvider\" | \"delete\" | \"deleteObject\" | \"deleteObjects\" | \"else\" | \"fromBytes\" | \"get\" | \"getObject\" | \"headObject\" | \"if\" | \"isBlank\" | \"isEmpty\" | \"iterateAll\" | \"key\" | \"list\" | \"listObjectsV2\" | \"map\" | \"mapNotNull\" | \"model\" | \"name\" | \"objects\" | \"of\" | \"parseS3Location\" | \"parseStorageUri\" | \"prefix\" | \"putObject\" | \"readAllBytes\" | \"region\" | \"resolveLocation\" | \"return 0\" | \"return StorageUri.of(\\\"s3://${location.bucket}/${location.key}\\\")\" | \"return false\" | \"return null\" | \"return parseS3Location(storageUri, properties.bucket)\n ?: run {\n if (storageUri.startsWith(\\\"s3://\\\")) {\n logger.warn { \\\"Invalid storage URI: $storageUri\\\" }\n }\n null\n }\" | \"return response.contents().map { obj -> StorageUri.of(\\\"s3://${location.bucket}/${obj.key()}\\\") }\" | \"return try {\n s3Client.deleteObject(\n DeleteObjectRequest.builder()\n .bucket(location.bucket)\n .key(location.key)\n .build()\n )\n true\n } catch (ex: S3Exception) {\n if (ex.statusCode() == 404) false else throw ex\n }\" | \"return try {\n s3Client.getObject({ builder ->\n builder.bucket(location.bucket).key(location.key)\n }).readAllBytes()\n } catch (ex: NoSuchBucketException) {\n logger.warn { \\\"S3 bucket missing for object retrieval: ${location.bucket}\\\" }\n null\n } catch (ex: S3Exception) {\n logger.warn(ex) { \\\"Failed to load object from S3: ${storageUri.value}\\\" }\n null\n }\" | \"return try {\n s3Client.headObject(\n HeadObjectRequest.builder()\n .bucket(location.bucket)\n .key(location.key)\n .build()\n )\n true\n } catch (_: NoSuchBucketException) {\n false\n } catch (ex: S3Exception) {\n if (ex.statusCode() == 404) false else throw ex\n }\" | \"run\" | \"s3\" | \"services\" | \"startsWith\" | \"statusCode\" | \"sumOf\" | \"toList\" | \"trimEnd\" | \"trimStart\" | \"try\" | \"value\" | \"warn\")?+ \"size\"? \"throw ex\"? \"throw\"?", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.ObjectStorageProperties", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.stereotype.Component", + "import software.amazon.awssdk.auth.credentials.DefaultCredentialsProvider", + "import software.amazon.awssdk.regions.Region", + "import software.amazon.awssdk.services.s3.S3Client", + "import software.amazon.awssdk.services.s3.model.Delete", + "import software.amazon.awssdk.services.s3.model.DeleteObjectRequest", + "import software.amazon.awssdk.services.s3.model.DeleteObjectsRequest", + "import software.amazon.awssdk.services.s3.model.HeadObjectRequest", + "import software.amazon.awssdk.services.s3.model.ListObjectsV2Request", + "import software.amazon.awssdk.services.s3.model.NoSuchBucketException", + "import software.amazon.awssdk.services.s3.model.PutObjectRequest", + "import software.amazon.awssdk.services.s3.model.S3Exception", + "import software.amazon.awssdk.core.sync.RequestBody", + "import com.google.cloud.storage.BlobId", + "import com.google.cloud.storage.BlobInfo", + "import com.google.cloud.storage.Storage", + "import com.google.cloud.storage.StorageOptions", + "import java.net.URI", + "import software.amazon.awssdk.auth.credentials.AwsBasicCredentials", + "import software.amazon.awssdk.auth.credentials.StaticCredentialsProvider", + "import software.amazon.awssdk.services.s3.S3Configuration", + "import software.amazon.awssdk.services.s3.model.CreateBucketRequest", + "import software.amazon.awssdk.services.s3.model.HeadBucketRequest" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport.recreateTestCollection", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import io.qdrant.client.QdrantClient", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.junit.jupiter.api.BeforeEach", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.springframework.test.context.TestPropertySource", + "import org.testcontainers.junit.jupiter.Testcontainers" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/repository/graph", + "method_count": 23, + "imports": [ + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.model.graph.ImageData", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.model.graph.PageNode", + "import eu.corentic.springrag.model.graph.TextElement", + "import java.time.Instant", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.test.annotation.DirtiesContext", + "import org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.BeforeEach", + "import eu.corentic.springrag.model.graph.TableElement", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.springframework.context.annotation.Import" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/systemTest/kotlin/eu/corentic/springrag/system", + "method_count": 6, + "imports": [ + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.test.annotation.DirtiesContext", + "import org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_CLASS" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/config", + "method_count": 3, + "imports": [ + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.neo4j.driver.Driver", + "import org.springframework.data.neo4j.core.transaction.Neo4jTransactionManager", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.mockito.ArgumentMatchers.anyString", + "import org.mockito.ArgumentMatchers.contains", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.times", + "import org.mockito.Mockito.atLeastOnce", + "import org.mockito.Mockito.verify", + "import org.mockito.Mockito.`when`", + "import org.neo4j.driver.Result", + "import org.neo4j.driver.Session" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/health", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= (\"HealthCheckReply\" | \"`when`\" | \"collectionExistsAsync\" | \"getDefaultInstance\" | \"healthCheckAsync\" | \"immediateFuture\" | \"thenReturn\" | \"verifyConnectivityAsync\")+ \"failedFuture\"?+ \"immediateFailedFuture\"?+ \"completedFuture\"?+ \"IllegalStateException\"? (\"InterruptedException\" | \"TimeoutException\")? (\"Neo4jDriverHealthIndicator\" | \"QdrantVectorStoreHealthIndicator\" | \"assertEquals\" | \"assertTrue\" | \"block\" | \"code\" | \"currentThread\" | \"health\" | \"interrupted\" | \"isInterrupted\" | \"requireNotNull\" | \"status\")+", + "mdl_score": 1000000000000, + "imports": [ + "import java.util.concurrent.CompletableFuture", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.neo4j.driver.Driver", + "import org.mockito.Mockito.`when`", + "import com.google.common.util.concurrent.Futures", + "import io.qdrant.client.QdrantClient", + "import io.qdrant.client.grpc.QdrantOuterClass", + "import java.util.concurrent.TimeoutException", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/model/graph", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= (\"ImageData\" | \"PageNode\")?+ (\"PictureElement\" | \"SectionHeaderElement\")? \"copy\"?+ \"assertEquals\"?+ \"assertNotEquals\"? (\"hashCode\" | \"label\")?+", + "mdl_score": 6936, + "imports": [ + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotEquals", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotEquals" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/repository", + "method_count": 19, + "imports": [ + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.verify", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.document.Document", + "import org.springframework.ai.vectorstore.SearchRequest", + "import org.springframework.ai.vectorstore.VectorStore", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/cleanup", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.service.graph.GraphIngestionOrchestrator", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.verify", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.repository.VectorRepository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/graph", + "method_count": 30, + "algorithm": "CRX", + "grammar": "root ::= \"assertThrows\"? \"GraphDocument\"? \"IllegalArgumentException\"? \"java\"? (\"DocumentGraphJob\" | \"DocumentJobNode\" | \"GraphImagePayload\" | \"GraphPage\" | \"GraphPictureElement\" | \"GraphTableElement\" | \"GraphTextElement\" | \"Instant\" | \"String\" | \"activateDocument\" | \"activateDocumentGraph\" | \"adjustCounters\" | \"adjustSizeInBytes\" | \"any\" | \"arg\" | \"asDocumentId\" | \"asFilename\" | \"asJobId\" | \"asKnowledgeBaseId\" | \"asLogicalDocumentId\" | \"asStorageUri\" | \"assertDoesNotThrow\" | \"byteArrayOf\" | \"capture\" | \"corentic\" | \"countActiveDocumentsByLogicalDocumentId\" | \"countActiveElementsByLogicalDocumentId\" | \"createBelongsToRelationship\" | \"deactivateByLogicalDocumentId\" | \"deactivateByLogicalDocumentIdExcept\" | \"deleteByJobId\" | \"deleteObject\" | \"deleteObjects\" | \"emptyGraphDocument\" | \"emptyList\" | \"eu\" | \"every\" | \"existsById\" | \"findByJobId\" | \"findByKnowledgeBaseId\" | \"findByLogicalDocumentId\" | \"findOrCreateInactive\" | \"forEach\" | \"graph\" | \"isActive\" | \"listOf\" | \"minusSeconds\" | \"model\" | \"now\" | \"parse\" | \"repeat\" | \"saveDocumentGraph\" | \"slot\" | \"springrag\" | \"stageDocumentGraph\" | \"storeDocumentGraph\" | \"storeImage\" | \"stubDocumentGraphJob\" | \"sumActiveFileSizeBytesByLogicalDocumentId\" | \"time\" | \"value\" | \"verify\" | \"verifyOrder\")?+ \"GraphIngestionOrchestrator\"? \"captured\"? \"NoOpCircuitBreakerFactory\"? (\"assertEquals\" | \"assertNotNull\" | \"assertNull\" | \"doclingId\" | \"first\" | \"height\" | \"imageData\" | \"imageType\" | \"page\" | \"pageNo\" | \"pages\" | \"pictureElements\" | \"rendering\" | \"size\" | \"storageUri\" | \"textElements\" | \"width\")?+ \"text\"?", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphImagePayload", + "import eu.corentic.springrag.model.GraphPage", + "import eu.corentic.springrag.model.GraphPictureElement", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.service.port.DocumentGraphJobPort", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.testsupport.NoOpCircuitBreakerFactory", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import io.mockk.*", + "import io.mockk.impl.annotations.MockK", + "import io.mockk.junit5.MockKExtension", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.extension.ExtendWith" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/port/adapter", + "method_count": 28, + "imports": [ + "import eu.corentic.springrag.model.graph.ImageData", + "import eu.corentic.springrag.model.graph.TableElement", + "import eu.corentic.springrag.model.graph.TextElement", + "import eu.corentic.springrag.repository.graph.ImageDataRepository", + "import eu.corentic.springrag.repository.graph.TableElementRepository", + "import eu.corentic.springrag.repository.graph.TextElementRepository", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.util.Optional", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.model.DocumentGraphJob", + "import eu.corentic.springrag.model.graph.DocumentJobNode", + "import eu.corentic.springrag.model.graph.KnowledgeBaseNode", + "import eu.corentic.springrag.repository.graph.DocumentJobNodeRepository", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import java.time.Instant", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import eu.corentic.springrag.repository.graph.GraphMaintenanceRepository", + "import io.mockk.just", + "import io.mockk.runs", + "import eu.corentic.springrag.model.KnowledgeBase", + "import eu.corentic.springrag.repository.graph.KnowledgeBaseRepository", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/service/storage", + "method_count": 3, + "algorithm": "CRX", + "grammar": "root ::= \"assertNull\"? \"parseS3Location\" \"error\"?+ (\"assertEquals\" | \"bucket\")?+ \"key\"?", + "mdl_score": 272, + "imports": [ + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNull" + ], + "arg_patterns": {} + }, + { + "label": "infrastructure/adapters/search/src/test/kotlin/eu/corentic/springrag/testsupport", + "method_count": 3, + "imports": [ + "import java.util.function.Function", + "import java.util.function.Supplier", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreaker", + "import org.springframework.cloud.client.circuitbreaker.CircuitBreakerFactory", + "import org.springframework.cloud.client.circuitbreaker.ConfigBuilder" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/integrationTest/kotlin/eu/corentic/springrag/service/chat", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import org.springframework.boot.SpringBootConfiguration", + "import org.springframework.boot.autoconfigure.EnableAutoConfiguration", + "import org.springframework.context.annotation.Bean", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.every", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.mockk", + "import kotlinx.coroutines.runBlocking", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.test.context.TestConfiguration", + "import org.springframework.test.context.ActiveProfiles" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/main/kotlin/eu/corentic/springrag/service/chat", + "method_count": 6, + "algorithm": "CRX", + "grammar": "root ::= \"let\"?+ \"info\"?+ \"KnowledgeBaseId\"? \"defaultAgentId\"?+ (\"RagInvocation\" | \"RagRequest\" | \"invoke\" | \"return ragAgentInvocationGateway.invoke(\n RagInvocation(\n request = request,\n executionContext = AgentExecutionContext.http()\n )\n )\" | \"return ragAgentInvocationGateway.invoke(\n RagInvocation(\n request = request,\n executionContext = AgentExecutionContext.http(contextId = conversationId)\n )\n )\")?+ \"listCapabilities\"?+ \"http\"?+ \"map\"?+ \"filter\"?+ \"id\"? \"AgentCapabilityDescriptor\"?", + "mdl_score": 1345, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.capability.isExposedOverHttp", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import jakarta.annotation.PostConstruct", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Service" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/systemTest/kotlin/eu/corentic/springrag/config", + "method_count": 15, + "imports": [ + "import eu.corentic.springrag.testcontainers.OllamaModelSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport", + "import eu.corentic.springrag.testcontainers.QdrantTestSupport.recreateTestCollection", + "import eu.corentic.springrag.testcontainers.SharedContainers", + "import eu.corentic.springrag.testcontainers.SharedContainers.ContainerType", + "import io.qdrant.client.QdrantClient", + "import java.time.Duration", + "import java.time.Instant", + "import java.util.UUID", + "import org.junit.jupiter.api.Assumptions", + "import org.junit.jupiter.api.BeforeAll", + "import org.junit.jupiter.api.BeforeEach", + "import org.neo4j.driver.Driver", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.jdbc.core.JdbcTemplate", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.test.context.ActiveProfiles", + "import org.springframework.test.context.DynamicPropertyRegistry", + "import org.springframework.test.context.DynamicPropertySource", + "import org.springframework.test.context.TestPropertySource", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.testcontainers.junit.jupiter.Testcontainers", + "import java.sql.Timestamp", + "import org.springframework.ai.chat.memory.ChatMemory", + "import org.springframework.ai.chat.memory.ChatMemoryRepository", + "import org.springframework.ai.chat.memory.MessageWindowChatMemory", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.boot.SpringBootConfiguration", + "import org.springframework.boot.autoconfigure.EnableAutoConfiguration", + "import org.springframework.boot.context.properties.ConfigurationPropertiesScan", + "import org.springframework.context.annotation.ComponentScan", + "import org.springframework.data.neo4j.repository.config.EnableNeo4jRepositories", + "import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories", + "import org.springframework.jdbc.datasource.DataSourceTransactionManager", + "import org.springframework.transaction.PlatformTransactionManager", + "import javax.sql.DataSource", + "import ai.docling.serve.api.DoclingServeApi", + "import ai.docling.serve.client.DoclingServeClientBuilderFactory", + "import java.lang.reflect.InvocationTargetException" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/systemTest/kotlin/eu/corentic/springrag/system", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.config.BaseSystemTest", + "import eu.corentic.springrag.controller.SessionChatRequest", + "import eu.corentic.springrag.model.ChatResponse", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.repository.VectorRepository", + "import java.time.Duration", + "import kotlinx.coroutines.runBlocking", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.springframework.ai.chat.memory.ChatMemory", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.webtestclient.autoconfigure.AutoConfigureWebTestClient", + "import org.springframework.test.web.reactive.server.WebTestClient", + "import org.springframework.test.web.reactive.server.returnResult" + ], + "arg_patterns": {} + }, + { + "label": "modules/chat/src/test/kotlin/eu/corentic/springrag/service/chat", + "method_count": 8, + "imports": [ + "import eu.corentic.springrag.agent.capability.AgentCapabilityDirectory", + "import eu.corentic.springrag.agent.capability.AgentExecutionContext", + "import eu.corentic.springrag.agent.rag.RagAgentInvocationGateway", + "import eu.corentic.springrag.agent.rag.RagInvocation", + "import eu.corentic.springrag.agent.rag.RagRequest", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.model.ChatResponse", + "import io.mockk.coEvery", + "import io.mockk.coVerify", + "import io.mockk.every", + "import io.mockk.mockk", + "import kotlinx.coroutines.test.StandardTestDispatcher", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.agent.capability.AgentCapabilityDescriptor", + "import org.junit.jupiter.api.BeforeEach" + ], + "arg_patterns": {} + }, + { + "label": "modules/common/src/main/kotlin/eu/corentic/springrag/common", + "method_count": 7, + "imports": [], + "arg_patterns": {} + }, + { + "label": "modules/common/src/main/kotlin/eu/corentic/springrag/common/ids", + "method_count": 18, + "algorithm": "CRX", + "grammar": "root ::= (\"removeSuffix\" | \"trim\")?+ \"of\"?+ \"requireNonBlankNoWhitespace\"? (\"DocumentId\" | \"JobId\" | \"KnowledgeBaseId\" | \"LogicalDocumentId\")? \"trimStart\"?+ \"requireSafeId\"? \"return StorageUri(\\\"$base/$relative\\\")\"? \"StorageUri\"? \"requireNonBlank\"? (\"contains\" | \"isNotEmpty\" | \"require\")?+ \"any\"?+ \"matches\"?+ \"return BatchId(normalized)\"? \"return Filename(normalized)\"? \"isWhitespace\"?+ \"BatchId\"? \"Filename\"? \"return normalized\"?", + "mdl_score": 3509058, + "imports": [], + "arg_patterns": {} + }, + { + "label": "modules/common/src/test/kotlin/eu/corentic/springrag/common/ids", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= (\"IllegalArgumentException\" | \"asBatchId\" | \"asDocumentId\" | \"asFilename\" | \"asJobId\" | \"asKnowledgeBaseId\" | \"asLogicalDocumentId\" | \"asStorageUri\" | \"assertEquals\" | \"assertFailsWith\" | \"of\" | \"value\")+", + "mdl_score": 1000000000000, + "imports": [ + "import kotlin.test.Test", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFailsWith" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/integrationTest/kotlin/eu/corentic/springrag/service/job", + "method_count": 34, + "imports": [ + "import com.ninjasquad.springmockk.MockkBean", + "import eu.corentic.springrag.batch.DocumentIngestionJobConfig", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.processor.DocumentProcessingItemProcessor", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import io.mockk.clearMocks", + "import io.mockk.every", + "import java.io.File", + "import java.time.Duration", + "import org.awaitility.Awaitility.await", + "import org.junit.jupiter.api.Assertions", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.beans.factory.annotation.Autowired", + "import org.springframework.boot.test.context.SpringBootTest", + "import org.springframework.test.context.ActiveProfiles", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.springframework.jdbc.core.JdbcTemplate", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.batch.listener.BatchJobListener", + "import eu.corentic.springrag.batch.listener.SimpleDocumentTrackingListener", + "import eu.corentic.springrag.batch.partition.DocumentPartitioner", + "import eu.corentic.springrag.batch.reader.FileBasedDocumentItemReader", + "import eu.corentic.springrag.batch.writer.GraphStoreItemWriter", + "import java.nio.file.Files", + "import java.util.concurrent.CountDownLatch", + "import java.util.concurrent.TimeUnit", + "import java.util.concurrent.atomic.AtomicLong", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.core.launch.JobOperator", + "import org.junit.jupiter.api.Assertions.assertNull", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import java.util.concurrent.ConcurrentHashMap", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.context.annotation.Profile" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch", + "method_count": 16, + "imports": [ + "import eu.corentic.springrag.batch.listener.BatchJobListener", + "import eu.corentic.springrag.batch.listener.DocumentActivationWriteListener", + "import eu.corentic.springrag.batch.listener.DocumentIngestionStageWriteListener", + "import eu.corentic.springrag.batch.listener.SimpleDocumentTrackingListener", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.partition.DocumentPartitioner", + "import eu.corentic.springrag.batch.processor.DocumentProcessingItemProcessor", + "import eu.corentic.springrag.batch.reader.FileBasedDocumentItemReader", + "import eu.corentic.springrag.batch.writer.DocumentActivationWriter", + "import eu.corentic.springrag.batch.writer.DocumentIngestionStageWriter", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.config.BatchProperties", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import javax.sql.DataSource", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.batch.core.configuration.annotation.StepScope", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.job.builder.JobBuilder", + "import org.springframework.batch.core.repository.JobRepository", + "import org.springframework.batch.core.partition.PartitionHandler", + "import org.springframework.batch.core.partition.support.TaskExecutorPartitionHandler", + "import org.springframework.batch.core.step.Step", + "import org.springframework.batch.core.step.builder.StepBuilder", + "import org.springframework.batch.core.step.skip.SkipPolicy", + "import org.springframework.batch.core.listener.SkipListener", + "import org.springframework.batch.infrastructure.item.database.JdbcCursorItemReader", + "import org.springframework.batch.infrastructure.item.database.builder.JdbcCursorItemReaderBuilder", + "import org.springframework.beans.factory.annotation.Qualifier", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.core.task.TaskExecutor", + "import org.springframework.core.retry.RetryPolicy", + "import org.springframework.dao.TransientDataAccessException", + "import org.springframework.transaction.PlatformTransactionManager", + "import org.springframework.util.backoff.FixedBackOff", + "import java.io.IOException", + "import eu.corentic.springrag.service.chunk.DocumentChunkService", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import org.springframework.batch.infrastructure.item.ItemProcessor", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/listener", + "method_count": 16, + "imports": [ + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.batch.core.BatchStatus", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.listener.JobExecutionListener", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import org.springframework.batch.core.listener.ItemWriteListener", + "import org.springframework.batch.core.listener.SkipListener", + "import org.springframework.batch.infrastructure.item.Chunk", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import org.springframework.batch.core.listener.ItemProcessListener" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/model", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import java.time.Instant" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/partition", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import java.nio.file.FileSystems", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import kotlin.streams.toList", + "import org.springframework.batch.core.configuration.annotation.StepScope", + "import org.springframework.batch.core.partition.Partitioner", + "import org.springframework.batch.infrastructure.item.ExecutionContext", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.stereotype.Component" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/reader", + "method_count": 4, + "imports": [ + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.document.DocumentIdentity", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.batch.infrastructure.item.ExecutionContext", + "import org.springframework.batch.infrastructure.item.ItemStreamReader", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.core.io.ResourceLoader", + "import java.util.concurrent.ConcurrentLinkedQueue" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/batch/writer", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.service.job.DocumentActivationService", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import org.springframework.batch.infrastructure.item.Chunk", + "import org.springframework.batch.infrastructure.item.ItemWriter", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.service.chunk.EmbeddingInputGuard", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import io.github.oshai.kotlinlogging.KotlinLogging" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/config", + "method_count": 26, + "imports": [ + "import javax.sql.DataSource", + "import org.springframework.batch.core.configuration.support.JdbcDefaultBatchConfiguration", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.core.task.TaskDecorator", + "import org.springframework.core.task.TaskExecutor", + "import org.springframework.core.task.VirtualThreadTaskExecutor", + "import org.springframework.core.task.support.TaskExecutorAdapter", + "import org.springframework.jdbc.datasource.DataSourceTransactionManager", + "import org.springframework.transaction.PlatformTransactionManager", + "import org.springframework.transaction.annotation.Isolation", + "import eu.corentic.springrag.common.ids.BatchId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.StorageUri", + "import jakarta.annotation.PostConstruct", + "import jakarta.validation.constraints.NotBlank", + "import java.net.URI", + "import java.nio.file.Path", + "import java.time.Duration", + "import org.slf4j.LoggerFactory", + "import org.springframework.boot.context.properties.ConfigurationProperties", + "import org.springframework.validation.annotation.Validated" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/chunk", + "method_count": 18, + "imports": [ + "import eu.corentic.springrag.config.HybridChunkingConfig", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import org.springframework.stereotype.Service", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.config.EmbabelModelProperties", + "import kotlin.math.min", + "import com.knuddels.jtokkit.Encodings", + "import com.knuddels.jtokkit.api.Encoding", + "import com.knuddels.jtokkit.api.EncodingType" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/document", + "method_count": 3, + "imports": [ + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import java.security.MessageDigest" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/main/kotlin/eu/corentic/springrag/service/job", + "method_count": 62, + "imports": [ + "import java.sql.Timestamp", + "import java.time.Instant", + "import org.springframework.jdbc.core.JdbcTemplate", + "import org.springframework.stereotype.Component", + "from ingestion_batch_ownership", + "import eu.corentic.springrag.common.DomainException", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.stereotype.Service", + "import eu.corentic.springrag.model.event.DocumentActivationFailed", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import org.springframework.modulith.events.ApplicationModuleListener", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import org.springframework.context.ApplicationEventPublisher", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.batch.model.ErrorSeverity", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import eu.corentic.springrag.common.ids.Filename", + "import eu.corentic.springrag.common.ids.JobId", + "import java.sql.ResultSet", + "import org.springframework.transaction.annotation.Transactional", + "from ingestion_document_tracking", + "import eu.corentic.springrag.common.ids.DocumentId", + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.common.ids.LogicalDocumentId", + "import org.springframework.jdbc.core.RowMapper", + "from ingestion_document_state", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.repository.JobRepository", + "import eu.corentic.springrag.common.ids.StorageUri", + "import eu.corentic.springrag.config.StorageProperties", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import org.springframework.core.io.ResourceLoader", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.core.launch.JobOperator", + "import java.util.UUID", + "import org.springframework.batch.core.job.parameters.JobParametersBuilder", + "import java.io.File", + "import java.util.*", + "import org.springframework.batch.core.launch.JobExecutionAlreadyRunningException", + "import org.springframework.batch.core.launch.JobInstanceAlreadyCompleteException", + "import eu.corentic.springrag.batch.DocumentIngestionJobConfig", + "import org.springframework.batch.core.launch.NoSuchJobException", + "import eu.corentic.springrag.batch.model.ErrorSummary", + "import org.springframework.batch.core.BatchStatus", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import java.net.URI", + "import java.nio.file.Path", + "import org.springframework.scheduling.annotation.Scheduled", + "import org.springframework.util.FileSystemUtils" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch", + "method_count": 17, + "imports": [ + "import eu.corentic.springrag.config.BatchProperties", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import io.mockk.mockk", + "import kotlin.test.assertEquals", + "import org.junit.jupiter.api.Test", + "import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder", + "import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseType", + "import java.io.IOException", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import org.springframework.core.retry.RetryPolicy", + "import org.springframework.dao.TransientDataAccessResourceException", + "import org.springframework.util.backoff.FixedBackOff", + "import org.springframework.batch.core.step.skip.SkipPolicy", + "import kotlin.test.assertNotNull", + "import org.springframework.batch.core.listener.ItemProcessListener", + "import org.springframework.batch.core.listener.JobExecutionListener" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/listener", + "method_count": 34, + "imports": [ + "import eu.corentic.springrag.config.StorageProperties", + "import java.io.IOException", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.time.Duration", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir", + "import org.springframework.batch.core.BatchStatus", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.core.job.parameters.JobParametersBuilder", + "import org.springframework.batch.test.MetaDataInstanceFactory", + "import eu.corentic.springrag.service.job.StagedUploadCleanupService", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.mockk.mockk", + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.runs", + "import io.mockk.verify", + "import org.springframework.batch.infrastructure.item.Chunk", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.batch.model.ProcessingError", + "import java.io.EOFException", + "import java.net.SocketTimeoutException", + "import javax.net.ssl.SSLException", + "import kotlin.test.assertEquals", + "import eu.corentic.springrag.model.VectorChunk", + "import io.mockk.slot" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/model", + "method_count": 8, + "imports": [ + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotEquals", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/partition", + "method_count": 7, + "imports": [ + "import eu.corentic.springrag.service.job.DocumentTrackingRepository", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.verify", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/processor", + "method_count": 5, + "imports": [ + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.ParsedDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.chunk.DocumentChunkService", + "import eu.corentic.springrag.service.port.DocumentParserPort", + "import eu.corentic.springrag.service.port.DocumentParsingRequest", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.clearAllMocks", + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import java.util.UUID", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.assertThrows" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/reader", + "method_count": 12, + "imports": [ + "import eu.corentic.springrag.service.document.DocumentIdentity", + "import java.io.File", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import io.mockk.mockk", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.Test", + "import org.junit.jupiter.api.io.TempDir" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/batch/writer", + "method_count": 14, + "imports": [ + "import eu.corentic.springrag.service.job.DocumentActivationService", + "import eu.corentic.springrag.service.job.IngestionDocumentState", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import org.junit.jupiter.api.Test", + "import org.springframework.batch.infrastructure.item.Chunk", + "import kotlin.test.assertFailsWith", + "import eu.corentic.springrag.batch.model.DocumentInput", + "import eu.corentic.springrag.batch.model.ProcessedDocument", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.VectorChunk", + "import eu.corentic.springrag.service.chunk.EmbeddingInputGuard", + "import eu.corentic.springrag.service.chunk.EmbeddingInputTooLargeException", + "import eu.corentic.springrag.service.job.IngestionDocumentStateRepository", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import io.mockk.verify", + "import io.mockk.*", + "import io.mockk.impl.annotations.MockK", + "import io.mockk.junit5.MockKExtension", + "import kotlinx.coroutines.test.runTest", + "import org.junit.jupiter.api.AfterEach", + "import org.junit.jupiter.api.Assertions.*", + "import org.junit.jupiter.api.BeforeEach", + "import org.junit.jupiter.api.extension.ExtendWith" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/chunk", + "method_count": 8, + "imports": [ + "import eu.corentic.springrag.config.HybridChunkingConfig", + "import eu.corentic.springrag.config.EmbabelModelProperties", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import eu.corentic.springrag.model.GraphDocument", + "import eu.corentic.springrag.model.GraphTableElement", + "import eu.corentic.springrag.model.GraphTextElement", + "import eu.corentic.springrag.model.ParsedDocument", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import kotlin.test.assertTrue", + "import org.junit.jupiter.api.Test" + ], + "arg_patterns": {} + }, + { + "label": "modules/ingestion/src/test/kotlin/eu/corentic/springrag/service/job", + "method_count": 49, + "imports": [ + "import io.mockk.every", + "import io.mockk.mockk", + "import io.mockk.verify", + "import kotlin.test.assertEquals", + "import kotlin.test.assertFailsWith", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.model.event.DocumentActivationFailed", + "import eu.corentic.springrag.service.port.ChunkIndexPort", + "import eu.corentic.springrag.common.ids.asDocumentId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import eu.corentic.springrag.common.ids.asLogicalDocumentId", + "import io.mockk.just", + "import io.mockk.runs", + "import eu.corentic.springrag.service.port.GraphIndexPort", + "import eu.corentic.springrag.common.ids.asFilename", + "import eu.corentic.springrag.common.ids.asJobId", + "import org.springframework.context.ApplicationEventPublisher", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import java.time.LocalDateTime", + "import kotlin.test.assertNull", + "import org.springframework.batch.core.job.JobExecution", + "import org.springframework.batch.core.job.JobInstance", + "import org.springframework.batch.core.job.parameters.JobParametersBuilder", + "import org.springframework.batch.core.repository.JobRepository", + "import java.io.File", + "import eu.corentic.springrag.common.ids.asStorageUri", + "import eu.corentic.springrag.service.port.ObjectStoragePort", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.springframework.core.io.DefaultResourceLoader", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertSame", + "import org.junit.jupiter.api.assertThrows", + "import org.slf4j.MDC", + "import org.springframework.batch.core.job.Job", + "import org.springframework.batch.core.launch.JobOperator", + "import kotlin.test.assertNotNull", + "import io.mockk.slot", + "import org.junit.jupiter.api.Assertions.assertNotEquals", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.springframework.batch.core.BatchStatus", + "import org.springframework.batch.core.launch.JobExecutionAlreadyRunningException", + "import org.springframework.batch.core.launch.JobInstanceAlreadyCompleteException", + "import org.springframework.batch.core.job.parameters.JobParameters", + "import org.springframework.batch.test.MetaDataInstanceFactory", + "import kotlin.test.assertTrue", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.config.StorageProperties", + "import java.nio.file.Files", + "import java.nio.file.Path", + "import java.time.Duration", + "import java.time.Instant", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.io.TempDir" + ], + "arg_patterns": {} + }, + { + "label": "modules/knowledgebase/ports/src/main/kotlin/eu/corentic/springrag/model", + "method_count": 5, + "imports": [ + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import java.time.Instant" + ], + "arg_patterns": {} + }, + { + "label": "modules/knowledgebase/src/main/kotlin/eu/corentic/springrag/service/knowledgebase", + "method_count": 11, + "imports": [ + "import eu.corentic.springrag.common.ids.KnowledgeBaseId", + "import eu.corentic.springrag.model.KnowledgeBase", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.beans.factory.annotation.Value", + "import org.springframework.boot.CommandLineRunner", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import java.time.Instant", + "import eu.corentic.springrag.common.ids.JobId", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import org.springframework.context.ApplicationEventPublisher", + "import org.springframework.stereotype.Service", + "import org.springframework.transaction.annotation.Transactional", + "import java.util.*" + ], + "arg_patterns": {} + }, + { + "label": "modules/knowledgebase/src/test/kotlin/eu/corentic/springrag/service/knowledgebase", + "method_count": 16, + "imports": [ + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Test", + "import jakarta.validation.Validation", + "import kotlin.test.assertFalse", + "import kotlin.test.assertTrue", + "import eu.corentic.springrag.model.event.DocumentDeletionRequested", + "import eu.corentic.springrag.model.event.KnowledgeBaseDeletionRequested", + "import eu.corentic.springrag.service.port.KnowledgeBasePort", + "import eu.corentic.springrag.service.port.KnowledgeBaseDocumentPort", + "import eu.corentic.springrag.common.ids.asJobId", + "import eu.corentic.springrag.common.ids.asKnowledgeBaseId", + "import io.mockk.every", + "import io.mockk.just", + "import io.mockk.mockk", + "import io.mockk.runs", + "import io.mockk.slot", + "import io.mockk.verify", + "import java.time.Instant", + "import kotlin.test.assertEquals", + "import kotlin.test.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.springframework.context.ApplicationEventPublisher" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/main/kotlin/eu/corentic/springrag/security/config", + "method_count": 5, + "imports": [ + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.service.JwtService", + "import org.springframework.http.HttpHeaders", + "import org.springframework.security.authentication.UsernamePasswordAuthenticationToken", + "import org.springframework.security.core.context.ReactiveSecurityContextHolder", + "import org.springframework.stereotype.Component", + "import org.springframework.web.server.ServerWebExchange", + "import org.springframework.web.server.WebFilter", + "import org.springframework.web.server.WebFilterChain", + "import reactor.core.publisher.Mono", + "import org.springframework.context.annotation.Bean", + "import org.springframework.context.annotation.Configuration", + "import org.springframework.security.config.annotation.method.configuration.EnableReactiveMethodSecurity", + "import org.springframework.security.config.annotation.web.reactive.EnableWebFluxSecurity", + "import org.springframework.security.config.web.server.SecurityWebFiltersOrder", + "import org.springframework.security.config.web.server.ServerHttpSecurity", + "import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.security.web.server.SecurityWebFilterChain", + "import org.springframework.security.authentication.ReactiveAuthenticationManager", + "import org.springframework.security.core.userdetails.ReactiveUserDetailsService", + "import org.springframework.security.authentication.UserDetailsRepositoryReactiveAuthenticationManager", + "import org.springframework.security.web.server.csrf.CookieServerCsrfTokenRepository", + "import org.springframework.security.web.server.csrf.CsrfWebFilter", + "import org.springframework.security.web.server.util.matcher.AndServerWebExchangeMatcher", + "import org.springframework.security.web.server.util.matcher.NegatedServerWebExchangeMatcher", + "import org.springframework.security.web.server.util.matcher.ServerWebExchangeMatchers", + "import org.springframework.core.env.Environment", + "import org.springframework.core.env.Profiles", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.service.UserService", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.boot.CommandLineRunner", + "import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/main/kotlin/eu/corentic/springrag/security/service", + "method_count": 10, + "imports": [ + "import eu.corentic.springrag.security.repository.UserRepository", + "import org.springframework.security.core.userdetails.ReactiveUserDetailsService", + "import org.springframework.security.core.userdetails.User", + "import org.springframework.security.core.userdetails.UserDetails", + "import org.springframework.stereotype.Service", + "import reactor.core.publisher.Mono", + "import reactor.core.scheduler.Schedulers", + "import eu.corentic.springrag.common.DomainException", + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.model.User", + "import io.jsonwebtoken.ExpiredJwtException", + "import io.jsonwebtoken.Jwts", + "import io.jsonwebtoken.MalformedJwtException", + "import io.jsonwebtoken.UnsupportedJwtException", + "import io.jsonwebtoken.security.Keys", + "import io.jsonwebtoken.security.SecurityException", + "import java.nio.charset.StandardCharsets", + "import java.util.*", + "import javax.crypto.SecretKey", + "import eu.corentic.springrag.security.config.JwtProperties", + "import org.springframework.security.core.GrantedAuthority", + "import org.springframework.security.core.authority.SimpleGrantedAuthority", + "import java.util.UUID", + "import org.springframework.data.relational.core.mapping.event.BeforeConvertCallback", + "import org.springframework.stereotype.Component", + "import eu.corentic.springrag.security.model.Role", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import org.springframework.security.crypto.password.PasswordEncoder", + "import org.springframework.transaction.annotation.Transactional" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/test/kotlin/eu/corentic/springrag/security/config", + "method_count": 6, + "imports": [ + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.service.JwtService", + "import eu.corentic.springrag.security.service.JwtValidationError", + "import io.mockk.every", + "import io.mockk.mockk", + "import java.util.concurrent.atomic.AtomicReference", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertNull", + "import org.junit.jupiter.api.Test", + "import org.springframework.http.HttpHeaders", + "import org.springframework.mock.http.server.reactive.MockServerHttpRequest", + "import org.springframework.mock.web.server.MockServerWebExchange", + "import org.springframework.security.core.Authentication", + "import org.springframework.security.core.authority.SimpleGrantedAuthority", + "import org.springframework.security.core.context.ReactiveSecurityContextHolder", + "import org.springframework.web.server.WebFilterChain", + "import org.junit.jupiter.api.Assertions.assertNotNull", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.springframework.mock.env.MockEnvironment", + "import org.springframework.security.authentication.ReactiveAuthenticationManager", + "import org.springframework.security.config.web.server.ServerHttpSecurity", + "import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder", + "import reactor.core.publisher.Mono", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.service.UserService", + "import io.mockk.just", + "import io.mockk.runs", + "import io.mockk.verify" + ], + "arg_patterns": {} + }, + { + "label": "modules/security/src/test/kotlin/eu/corentic/springrag/security/service", + "method_count": 15, + "algorithm": "CRX", + "grammar": "root ::= (\"encode\" | \"every\" | \"existsByUsername\")?+ \"JwtService\"? \"init\"?+ \"JwtProperties\"? \"UserService\"? \"hmacShaKeyFor\"?+ \"generateToken\"?+ \"toByteArray\"?+ \"assertFalse\"? \"UTF_8\"? \"builder\"?+ \"subject\"?+ \"issuedAt\"?+ (\"Date\" | \"expiration\")?+ \"currentTimeMillis\"?+ \"signWith\"?+ \"compact\"?+ (\"Err\" | \"Outcome\" | \"PasswordPolicyViolationException\" | \"ROLE_USER\" | \"String\" | \"UserAlreadyExistsException\" | \"any\" | \"assertEquals\" | \"assertThrows\" | \"assertTrue\" | \"authorities\" | \"authority\" | \"emptyList\" | \"error\" | \"extractAuthorities\" | \"extractUsername\" | \"firstArg\" | \"getOrThrow\" | \"java\" | \"listOf\" | \"map\" | \"match\" | \"parseToken\" | \"password\" | \"registerUser\" | \"role\" | \"save\" | \"username\" | \"validateToken\" | \"verify\")?+ \"JwtValidationError\"? \"errorCode\"? (\"Expired\" | \"InvalidSignature\" | \"Malformed\")?", + "mdl_score": 1000000000000, + "imports": [ + "import eu.corentic.springrag.common.Outcome", + "import eu.corentic.springrag.security.model.Role", + "import eu.corentic.springrag.security.model.User", + "import eu.corentic.springrag.security.config.JwtProperties", + "import io.jsonwebtoken.Jwts", + "import io.jsonwebtoken.security.Keys", + "import java.nio.charset.StandardCharsets", + "import java.util.UUID", + "import java.util.Date", + "import org.junit.jupiter.api.Assertions.assertEquals", + "import org.junit.jupiter.api.Assertions.assertFalse", + "import org.junit.jupiter.api.Assertions.assertTrue", + "import org.junit.jupiter.api.Test", + "import eu.corentic.springrag.security.repository.UserRepository", + "import io.mockk.MockKAnnotations", + "import io.mockk.every", + "import io.mockk.impl.annotations.MockK", + "import io.mockk.verify", + "import org.junit.jupiter.api.Assertions.assertThrows", + "import org.junit.jupiter.api.BeforeEach", + "import org.springframework.security.crypto.password.PasswordEncoder" + ], + "arg_patterns": {} + }, + { + "label": "platform/test-support/src/main/kotlin/eu/corentic/springrag/testcontainers", + "method_count": 13, + "imports": [ + "import com.github.dockerjava.api.model.DeviceRequest", + "import org.testcontainers.DockerClientFactory", + "import org.testcontainers.containers.GenericContainer", + "import io.github.oshai.kotlinlogging.KotlinLogging", + "import io.qdrant.client.QdrantClient", + "import io.qdrant.client.grpc.Collections.Distance", + "import io.qdrant.client.grpc.Collections.VectorParams", + "import java.util.concurrent.ExecutionException", + "import eu.corentic.springrag.testcontainers.GpuSupport.withGpuIfAvailable", + "import java.io.File", + "import java.time.Duration", + "import org.testcontainers.containers.BindMode", + "import org.testcontainers.containers.Neo4jContainer", + "import org.testcontainers.containers.PostgreSQLContainer", + "import org.testcontainers.containers.wait.strategy.Wait", + "import org.testcontainers.junit.jupiter.Container" + ], + "arg_patterns": {} + }, + { + "label": "platform/test-support/src/test/kotlin/eu/corentic/springrag/testcontainers", + "method_count": 5, + "imports": [ + "import org.junit.jupiter.api.Test", + "import org.mockito.Mockito.mock", + "import org.mockito.Mockito.times", + "import org.mockito.Mockito.verify", + "import org.testcontainers.containers.Container", + "import org.testcontainers.containers.GenericContainer", + "import com.google.common.util.concurrent.Futures", + "import com.google.common.util.concurrent.ListenableFuture", + "import io.qdrant.client.QdrantClient", + "import io.qdrant.client.grpc.Collections", + "import org.junit.jupiter.api.assertThrows", + "import org.mockito.ArgumentMatchers.any", + "import org.mockito.Mockito.`when`", + "import kotlin.test.assertEquals", + "import kotlin.test.assertTrue" + ], + "arg_patterns": {} + }, + { + "label": "(other)", + "method_count": 6, + "imports": [], + "arg_patterns": {} + } + ], + "total_methods": 1609 + }, + { + "language": ".js", + "conventions": [ + { + "label": "compose/patches", + "method_count": 17, + "imports": [], + "arg_patterns": { + "require": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Set": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "generateShortLivedToken": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "filterFilesByAgentAccess": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getFiles": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "other", + "lit", + "other" + ] + } + ] + }, + "tool": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "new": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "EmbeddingPollerImpl": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Map": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "setTimeout": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "clearTimeout": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "testing/steps", + "method_count": 68, + "algorithm": "CRX", + "grammar": "root ::= (\"Promise\" | \"TEST_FILE\" | \"all\" | \"await\" | \"btn\" | \"chip\" | \"click\" | \"document\" | \"evaluate\" | \"expect\" | \"fc\" | \"fetch\" | \"fill\" | \"filter\" | \"first\" | \"form\" | \"generateSuffix\" | \"getByRole\" | \"goto\" | \"idPara\" | \"if\" | \"includes\" | \"isClosed\" | \"last\" | \"locator\" | \"modelBtn\" | \"querySelector\" | \"setFiles\" | \"suffix\" | \"textContent\" | \"waitFor\" | \"waitForEvent\" | \"waitForTimeout\" | \"waitForURL\")+ \"url\"? (\"toBe\" | \"toBeTruthy\" | \"toBeVisible\")? \"toContain\"?", + "mdl_score": 1000000000000, + "imports": [ + "import { Given, When, Then } from '@cucumber/cucumber';", + "import { expect } from '@playwright/test';", + "import { BeforeAll, AfterAll, Before, After, setDefaultTimeout } from '@cucumber/cucumber';" + ], + "arg_patterns": { + "When": { + "occurrences": 54, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 54, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "Then": { + "occurrences": 40, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 40, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "expect": { + "occurrences": 40, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 14, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "fetch": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Given": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "createAgent": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "setDefaultTimeout": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Before": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "After": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "testing/support", + "method_count": 3, + "imports": [ + "import { chromium } from '@playwright/test';", + "import { setWorldConstructor } from '@cucumber/cucumber';" + ], + "arg_patterns": { + "setWorldConstructor": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "(other)", + "method_count": 1, + "imports": [], + "arg_patterns": {} + } + ], + "total_methods": 89 + }, + { + "language": ".java", + "conventions": [], + "total_methods": 0 + }, + { + "language": ".go", + "conventions": [ + { + "label": "tools/setup-ui", + "method_count": 44, + "imports": [ + "import (" + ], + "arg_patterns": { + "writeEnvFile": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "float64": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "make": { + "occurrences": 9, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 9, + "args": 3, + "types": [ + "other", + "other", + "call" + ] + } + ] + }, + "len": { + "occurrences": 42, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "append": { + "occurrences": 51, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "var", + "call" + ] + }, + { + "count": 9, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 6, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "expr" + ] + } + ] + }, + "sectionTitle": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "string": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "writeExport": { + "occurrences": 8, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "other", + "call" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "var", + "var", + "other" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + } + ] + }, + "initialModel": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "buildSteps": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "runStart": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "errorStyle": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "summarizeConfig": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "accent": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "muted": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "banner": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "newConfig": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "removeString": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "sortedKeys": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "repoRoot": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "shellEscape": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isSensitiveKey": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + } + ], + "total_methods": 44 + } +] diff --git a/experiments/results/round20_ast_verify/zod.log b/experiments/results/round20_ast_verify/zod.log new file mode 100644 index 0000000..90829f8 --- /dev/null +++ b/experiments/results/round20_ast_verify/zod.log @@ -0,0 +1,51 @@ +[ 0.0s] Scanning /home/tobi/Desktop/dervish/external_refs/zod ... +[ 0.0s] Preprocessing 372 files across 12 workers ... +[ 9.7s] Preprocess: 6203 methods from 372 .ts files (9.7s) +[ 9.8s] Groups: 22 named, 4 ungrouped methods +[ 9.8s] ├ (1 methods) +[ 9.8s] ├ packages/bench (170 methods) +[ 9.8s] ├ packages/docs/app/llms-full.txt (3 methods) +[ 9.8s] ├ packages/docs/app/llms.txt (3 methods) +[ 9.8s] ├ packages/docs/content (16 methods) +[ 9.8s] ├ packages/docs/loaders (7 methods) +[ 9.8s] ├ packages/resolution (8 methods) +[ 9.8s] ├ packages/tsc (12 methods) +[ 9.8s] ├ packages/tsc/bench (3 methods) +[ 9.8s] ├ packages/zod/src/v3 (383 methods) +[ 9.8s] ├ packages/zod/src/v3/benchmarks (91 methods) +[ 9.8s] ├ packages/zod/src/v3/helpers (31 methods) +[ 9.8s] ├ packages/zod/src/v3/tests (985 methods) +[ 9.8s] ├ packages/zod/src/v4/classic (409 methods) +[ 9.8s] ├ packages/zod/src/v4/classic/tests (2342 methods) +[ 9.8s] ├ packages/zod/src/v4/core (704 methods) +[ 9.8s] ├ packages/zod/src/v4/core/tests (43 methods) +[ 9.8s] ├ packages/zod/src/v4/core/tests/locales (85 methods) +[ 9.8s] ├ packages/zod/src/v4/locales (214 methods) +[ 9.8s] ├ packages/zod/src/v4/mini (199 methods) +[ 9.8s] ├ packages/zod/src/v4/mini/tests (484 methods) +[ 9.8s] ├ scripts (6 methods) +[ 9.8s] └ (other) (4 methods) +[ 9.8s] Inferring 22 groups across 12 workers ... +[ 10.1s] [1/22] (1 methods) done (0.3s) +[ 10.5s] [2/22] packages/docs/app/llms-full.txt (3 methods) done (0.7s) +[ 10.7s] [3/22] packages/docs/app/llms.txt (3 methods) done (0.9s) +[ 10.9s] [4/22] packages/tsc/bench (3 methods) done (1.1s) +[ 11.4s] [5/22] packages/zod/src/v3/helpers (31 methods) done (1.6s) +[ 11.6s] [6/22] packages/resolution (8 methods) done (1.7s) +[ 11.9s] [7/22] packages/zod/src/v3 (383 methods) done (2.1s) +[ 12.2s] [8/22] packages/tsc (12 methods) done (2.4s) +[ 13.1s] [9/22] packages/docs/loaders (7 methods) done (3.2s) +[ 13.8s] [10/22] packages/zod/src/v4/core/tests (43 methods) done (3.9s) +[ 14.0s] [11/22] packages/docs/content (16 methods) done (4.2s) +[ 14.1s] [12/22] packages/zod/src/v4/mini (199 methods) done (4.3s) +[ 14.7s] [13/22] scripts (6 methods) done (4.9s) +[ 14.8s] [14/22] packages/zod/src/v4/classic (409 methods) done (5.0s) +[ 15.1s] [15/22] packages/zod/src/v3/benchmarks (91 methods) done (5.3s) +[ 18.1s] [16/22] packages/zod/src/v4/core (704 methods) done (8.3s) +[ 18.4s] [17/22] packages/zod/src/v4/mini/tests (484 methods) done (8.5s) +[ 18.6s] [18/22] packages/zod/src/v4/core/tests/locales (85 methods) done (8.8s) +[ 19.0s] [19/22] packages/bench (170 methods) done (9.1s) +[ 21.9s] [20/22] packages/zod/src/v4/locales (214 methods) done (12.1s) +[ 22.9s] [21/22] packages/zod/src/v3/tests (985 methods) done (13.1s) +[ 24.0s] [22/22] packages/zod/src/v4/classic/tests (2342 methods) done (14.2s) +[ 24.0s] Preprocessing 2 files across 12 workers ... diff --git a/experiments/results/round20_ast_verify/zod_grammars.json b/experiments/results/round20_ast_verify/zod_grammars.json new file mode 100644 index 0000000..6dbf8c3 --- /dev/null +++ b/experiments/results/round20_ast_verify/zod_grammars.json @@ -0,0 +1,13348 @@ +[ + { + "language": ".ts", + "conventions": [ + { + "label": "", + "method_count": 1, + "imports": [ + "import { z } from \"zod\";" + ], + "arg_patterns": {} + }, + { + "label": "packages/bench", + "method_count": 170, + "algorithm": "CRX", + "grammar": "root ::= (\"DATA\" | \"Math\" | \"Object\" | \"ZOD_FAILURE\" | \"_\" | \"as\" | \"d\" | \"for\" | \"if\" | \"new\" | \"of\" | \"parse\" | \"random\" | \"randomString\" | \"return\" | \"string\" | \"test\" | \"typeof\" | \"value\" | \"x\" | \"z\" | \"zod3\" | \"zod4\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { makeData, makeSchema, randomString } from \"./benchUtil.js\";", + "import { metabench } from \"./metabench.js\";", + "import * as zod3 from \"zod3\";", + "import * as zod4 from \"zod4\";", + "import * as zodNext from \"../zod/src/index.js\";", + "import { makeData, makeSchema } from \"./benchUtil.js\";", + "import { makeData, randomPick, randomString } from \"./benchUtil.js\";", + "import * as z3 from \"zod/v3\";", + "import * as z4 from \"zod/v4\";", + "import * as z4lib from \"zod4/v4\";", + "import { makeData } from \"./benchUtil.js\";", + "import * as z from \"zod/v3\";", + "import { execa } from \"execa\";", + "import * as z4 from \"zod\";", + "import * as z3 from \"zod3\";", + "import * as z4lib from \"zod4\";", + "import * as z4 from \"zod/mini\";", + "import { randomString } from \"./benchUtil.js\";", + "import { makeData, randomString } from \"./benchUtil.js\";", + "import { type } from \"arktype\";", + "import * as v from \"valibot\";", + "import * as z from \"zod/v4\";", + "import Benchmark from \"benchmark\";", + "import chalk from \"chalk\";", + "import { Table } from \"console-table-printer\";", + "import * as mitata from \"mitata\";", + "import { Bench } from \"tinybench\";", + "import { formatNumber } from \"./benchUtil.js\";", + "import { DATA, zod3, zod4 } from \"./object-setup.js\";", + "import { benchWithData } from \"./metabench.js\";", + "import { zod4, zodNext } from \"./benchUtil.js\";", + "import { randomString, zod4, zodNext } from \"./benchUtil.js\";", + "import { makeSchema } from \"./benchUtil.js\";" + ], + "arg_patterns": { + "makeData": { + "occurrences": 22, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 22, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "makeSchema": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "metabench": { + "occurrences": 58, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 46, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodFailure": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "typeofThenCheckSymbol": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "nullChainCheckSymbol": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "instanceofObjectThenCheckSymbol": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "keyin": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "falsyThenCheckSymbol": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "instanceofPromise": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "falsyThenCheckTag": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "typeofThenCheckTag": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "nullChainCheckTag": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "instanceofClass": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "instanceofObjectThenCheckTag": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "new": { + "occurrences": 23, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "expr" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "randomString": { + "occurrences": 54, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 54, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "randomPick": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Mitata": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "expr" + ] + } + ] + }, + "Error": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "template" + ] + } + ] + }, + "Bench": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Table": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "formatNumber": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "String": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "BenchmarkJS": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "expr" + ] + } + ] + }, + "Tinybench": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "expr" + ] + } + ] + }, + "_bench": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "toFixed": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 16, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "factory": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Date": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "lazyWithGetterOverride": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "lazyWithScopeProp": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getter": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "lazyWithInternalProp": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "benchWithData": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "makeSuccess": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "makeFail": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodFail": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "atschema": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "subscript" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "type": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Set": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "execa": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "$": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "run": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Proxy": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + } + } + }, + { + "label": "packages/docs/app/llms-full.txt", + "method_count": 3, + "imports": [ + "import * as fs from \"node:fs/promises\";", + "import { join } from \"node:path\";", + "import { getLLMText } from \"@/loaders/get-llm-text\";", + "import { source } from \"@/loaders/source\";" + ], + "arg_patterns": { + "join": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "call", + "lit", + "lit" + ] + } + ] + }, + "Response": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "Map": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "getLLMText": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "new": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 2, + "common": 0 + }, + "patterns": [ + { + "count": 1, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + } + } + }, + { + "label": "packages/docs/app/llms.txt", + "method_count": 3, + "imports": [ + "import { source } from \"@/loaders/source\";" + ], + "arg_patterns": { + "String": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "stringifyTitle": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Response": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "new": { + "occurrences": 1, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 1, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + } + } + }, + { + "label": "packages/docs/content", + "method_count": 16, + "algorithm": "CRX", + "grammar": "root ::= (\":\" | \"?\" | \"Array\" | \"Math\" | \"SourceLine\" | \"TabBlock\" | \"TabsBlock\" | \"_\" | \"actual\" | \"apiDocsPath\" | \"assertExpectedTabLabels\" | \"await\" | \"block\" | \"blockLine\" | \"blocks\" | \"codeFence\" | \"commentEnd\" | \"commentStart\" | \"compareCodeFences\" | \"comparedBlocks\" | \"continue\" | \"currentRow\" | \"currentTab\" | \"expect\" | \"expected\" | \"expectedValue\" | \"expressionValue\" | \"extractTabsBlocks\" | \"failures\" | \"fenceStartIndex\" | \"find\" | \"for\" | \"from\" | \"getEditDistance\" | \"getTabValue\" | \"hasZodMiniishTab\" | \"hasZodishTab\" | \"if\" | \"inCodeFence\" | \"index\" | \"indexOf\" | \"isFenceBoundary\" | \"isLikelyTabValue\" | \"left\" | \"leftIndex\" | \"line\" | \"lineCount\" | \"lines\" | \"match\" | \"mdxCommentState\" | \"min\" | \"normalizeTabValue\" | \"normalizedActual\" | \"normalizedExpected\" | \"of\" | \"previousRow\" | \"push\" | \"quotedValue\" | \"readCodeFence\" | \"readFile\" | \"result\" | \"return\" | \"right\" | \"rightIndex\" | \"slice\" | \"some\" | \"source\" | \"sourceLines\" | \"split\" | \"startsWith\" | \"state\" | \"string\" | \"stripMdxCommentSegments\" | \"stripMdxComments\" | \"substitutionCost\" | \"tab\" | \"tabValue\" | \"tabs\" | \"tabsBlocks\" | \"test\" | \"toBeGreaterThan\" | \"trimStart\" | \"while\" | \"zodFence\" | \"zodMiniFence\" | \"zodMiniTab\" | \"zodTab\")+ \"toEqual\"? \"value\"? \"toLowerCase\"? \"replaceAll\"?", + "mdl_score": 1000000000000, + "imports": [ + "import { readFile } from \"node:fs/promises\";", + "import { dirname, resolve } from \"node:path\";", + "import { fileURLToPath } from \"node:url\";", + "import { expect, test } from \"vitest\";" + ], + "arg_patterns": { + "normalizeTabValue": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "readFile": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "getTabValue": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "expect": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "stripMdxCommentSegments": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "readCodeFence": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "var", + "var", + "other" + ] + } + ] + }, + "compareCodeFences": { + "occurrences": 2, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 2, + "args": 4, + "types": [ + "var", + "var", + "var", + "var" + ] + } + ] + }, + "assertExpectedTabLabels": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "isLikelyTabValue": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "lit" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "resolve": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "lit" + ] + } + ] + }, + "dirname": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "getEditDistance": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "fileURLToPath": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "test": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "extractTabsBlocks": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "stripMdxComments": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "packages/docs/loaders", + "method_count": 7, + "algorithm": "CRX", + "grammar": "root ::= (\"API_URL\" | \"Array\" | \"Buffer\" | \"Error\" | \"GITHUB_TOKEN\" | \"JSON\" | \"Map\" | \"Set\" | \"_\" | \"a\" | \"as\" | \"await\" | \"b\" | \"catch\" | \"console\" | \"content\" | \"count\" | \"createElement\" | \"cwd\" | \"dir\" | \"error\" | \"fetch\" | \"fileContent\" | \"filePath\" | \"filter\" | \"for\" | \"from\" | \"fs\" | \"get\" | \"icon\" | \"icons\" | \"id\" | \"if\" | \"in\" | \"join\" | \"json\" | \"keyof\" | \"log\" | \"map\" | \"matter\" | \"name\" | \"new\" | \"number\" | \"of\" | \"owner\" | \"page\" | \"path\" | \"process\" | \"processed\" | \"processor\" | \"query\" | \"queryParts\" | \"r\" | \"readFile\" | \"relativePath\" | \"res\" | \"resolvedPath\" | \"resources\" | \"return\" | \"set\" | \"slug\" | \"sort\" | \"split\" | \"starsMap\" | \"string\" | \"stringify\" | \"throw\" | \"toString\" | \"try\" | \"typeof\" | \"uniqueSlugs\")+", + "mdl_score": 1000000000000, + "imports": [ + "import * as fs from \"node:fs/promises\";", + "import * as path from \"node:path\";", + "import type { source } from \"@/loaders/source\";", + "import type { InferPageType } from \"fumadocs-core/source\";", + "import { remarkInclude } from \"fumadocs-mdx/config\";", + "import matter from \"gray-matter\";", + "import { remark } from \"remark\";", + "import remarkGfm from \"remark-gfm\";", + "import remarkMdx from \"remark-mdx\";", + "import remarkStringify from \"remark-stringify\";", + "import { blogPosts, docs } from \"@/.source\";", + "import { loader } from \"fumadocs-core/source\";", + "import { createMDXSource } from \"fumadocs-mdx\";", + "import { icons } from \"lucide-react\";", + "import { createElement } from \"react\";" + ], + "arg_patterns": { + "matter": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "remark": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Map": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Set": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "fetch": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "Error": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "new": { + "occurrences": 5, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 1, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "loader": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "createElement": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "createMDXSource": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "packages/resolution", + "method_count": 8, + "algorithm": "CRX", + "grammar": "root ::= \"it\"?+ \"async\"? (\":\" | \"?\" | \"_\" | \"__dirname\" | \"any\" | \"await\" | \"buildTsc\" | \"buildZshy\" | \"catch\" | \"console\" | \"error\" | \"execa\" | \"existsSync\" | \"expect\" | \"if\" | \"join\" | \"log\" | \"output\" | \"outputWithoutFirstLine\" | \"path\" | \"result\" | \"return\" | \"slice\" | \"split\" | \"testCjs\" | \"testJs\" | \"testMjs\" | \"trim\" | \"try\" | \"warn\" | \"zodIndexPath\" | \"zodPackagePath\")+ \"toMatchInlineSnapshot\"? \"process\"? \"exit\"?", + "mdl_score": 1000000000000, + "imports": [ + "import { existsSync } from \"node:fs\";", + "import path from \"node:path\";", + "import { fileURLToPath } from \"node:url\";", + "import { execa } from \"execa\";", + "import { describe, expect, it } from \"vitest\";" + ], + "arg_patterns": { + "fileURLToPath": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "buildZshy": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "testJs": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "runAllTests": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "execa": { + "occurrences": 14, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 14, + "args": 3, + "types": [ + "lit", + "other", + "other" + ] + } + ] + }, + "testCjs": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "buildTsc": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "testMjs": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "describe": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "expect": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "it": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "lit", + "other", + "lit" + ] + } + ] + }, + "existsSync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "packages/tsc", + "method_count": 12, + "algorithm": "CRX", + "grammar": "root ::= \"_proc\"? (\"Array\" | \"Error\" | \"Math\" | \"charset\" | \"concat\" | \"console\" | \"continue\" | \"counter\" | \"custom\" | \"dirname\" | \"else\" | \"field\" | \"fields\" | \"file\" | \"filter\" | \"floor\" | \"for\" | \"from\" | \"generateFields\" | \"generated\" | \"i\" | \"if\" | \"imports\" | \"initialName\" | \"join\" | \"key\" | \"keys\" | \"kill\" | \"length\" | \"linked\" | \"log\" | \"map\" | \"methods\" | \"mkdirSync\" | \"mode\" | \"names\" | \"new\" | \"newFields\" | \"newName\" | \"numExtends\" | \"numOmits\" | \"numPicks\" | \"numRefs\" | \"numSchemas\" | \"of\" | \"omitFields\" | \"omitKeys\" | \"params\" | \"path\" | \"pickKeys\" | \"prevName\" | \"proc\" | \"procs\" | \"push\" | \"random\" | \"randomChainMethodIndex\" | \"randomIndex\" | \"randomStr\" | \"randomType\" | \"randomTypeIndex\" | \"result\" | \"return\" | \"schema\" | \"schemaType\" | \"slice\" | \"string\" | \"throw\" | \"type\" | \"variableName\" | \"varname\" | \"writeFileSync\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { $ } from \"execa\";", + "import * as gen from \"./generate.js\";", + "import { mkdirSync, writeFileSync } from \"node:fs\";", + "import { dirname } from \"node:path\";" + ], + "arg_patterns": { + "randomStr": { + "occurrences": 14, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 14, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "dirname": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "mkdirSync": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "generateFields": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "generateExtendChain": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "writeFileSync": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "call", + "other" + ] + } + ] + }, + "Error": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "new": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "$": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "packages/tsc/bench", + "method_count": 3, + "imports": [ + "import { execa } from \"execa\";" + ], + "arg_patterns": { + "$": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "execa": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "run": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "packages/zod/src/v3", + "method_count": 383, + "algorithm": "CRX", + "grammar": "root ::= (\":\" | \"?\" | \"INVALID\" | \"ZodFirstPartyTypeKind\" | \"ZodIssueCode\" | \"ZodParsedType\" | \"_addCheck\" | \"addIssueToContext\" | \"any\" | \"as\" | \"ch\" | \"create\" | \"ctx\" | \"data\" | \"dirty\" | \"else\" | \"errToObj\" | \"errorUtil\" | \"for\" | \"if\" | \"input\" | \"message\" | \"new\" | \"of\" | \"params\" | \"processCreateParams\" | \"result\" | \"return\" | \"status\" | \"toString\" | \"util\" | \"value\")+", + "mdl_score": 1000000000000, + "imports": [ + "import type { Primitive } from \"./helpers/typeAliases.js\";", + "import { util, type ZodParsedType } from \"./helpers/util.js\";", + "import type { TypeOf, ZodType } from \"./index.js\";", + "import type { ZodErrorMap } from \"./ZodError.js\";", + "import defaultErrorMap from \"./locales/en.js\";", + "import { type ZodErrorMap, ZodIssueCode } from \"../ZodError.js\";", + "import { util, ZodParsedType } from \"../helpers/util.js\";", + "import {", + "import { defaultErrorMap, getErrorMap } from \"./errors.js\";", + "import type { enumUtil } from \"./helpers/enumUtil.js\";", + "import { errorUtil } from \"./helpers/errorUtil.js\";", + "import type { partialUtil } from \"./helpers/partialUtil.js\";", + "import { util, ZodParsedType, getParsedType, type objectUtil } from \"./helpers/util.js\";", + "import type { StandardSchemaV1 } from \"./standard-schema.js\";" + ], + "arg_patterns": { + "mapper": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodError": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 14, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Error": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "processError": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "new": { + "occurrences": 125, + "arg_count": { + "min": 0, + "max": 4, + "common": 1 + }, + "patterns": [ + { + "count": 84, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 9, + "args": 0, + "types": [] + }, + { + "count": 7, + "args": 4, + "types": [ + "var", + "var", + "other", + "var" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodNever": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodBranded": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "OK": { + "occurrences": 28, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "timeRegexSource": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "deepPartialify": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ParseStatus": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "processCreateParams": { + "occurrences": 84, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 76, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "addIssueToContext": { + "occurrences": 148, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 146, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "mergeValues": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "subscript", + "subscript" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "setError": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "handleAsync": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "createZodEnum": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodObject": { + "occurrences": 28, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 28, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodEnum": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodLiteral": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getDiscriminator": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "makeIssue": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ParseInputLazyPath": { + "occurrences": 20, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 14, + "args": 4, + "types": [ + "var", + "var", + "other", + "var" + ] + }, + { + "count": 4, + "args": 4, + "types": [ + "var", + "var", + "other", + "other" + ] + }, + { + "count": 2, + "args": 4, + "types": [ + "var", + "subscript", + "other", + "var" + ] + } + ] + }, + "ZodArray": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "message": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "String": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodNullable": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isValid": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "makeReturnsIssue": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "Map": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 9, + "args": 0, + "types": [] + } + ] + }, + "check": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodMap": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getErrorMap": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "ZodOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getParsedType": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodNull": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodRecord": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodFunction": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodSymbol": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodBoolean": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodPromise": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "BigInt": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "timeRegex": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodUndefined": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "custom": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "isAborted": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodString": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getIssueProperties": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isAsync": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodBigInt": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "RegExp": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "params": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "makeArgsIssue": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "ZodNaN": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "handleParsed": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "call" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Date": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodUnknown": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodDiscriminatedUnion": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodEffects": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Set": { + "occurrences": 9, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ZodDate": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodSet": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "numberType": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "freeze": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isDirty": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Number": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "cleanParams": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "ZodDefault": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "This": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "handleResult": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "DIRTY": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodLazy": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodNumber": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodPipeline": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "floatSafeRemainder": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "isValidCidr": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "ZodReadonly": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodNativeEnum": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodTuple": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "executeRefinement": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "stringType": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "ZodAny": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodCatch": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "datetimeRegex": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "booleanType": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Boolean": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "atob": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "URL": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isValidIP": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "finalizeSet": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodVoid": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isValidJWT": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "refinementData": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "ZodIntersection": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodUnion": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Symbol": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + } + } + }, + { + "label": "packages/zod/src/v3/benchmarks", + "method_count": 91, + "algorithm": "CRX", + "grammar": "root ::= \"console\"? \"try\"? \"log\"? (\"double\" | \"many\" | \"stringSchema\")? \"as\"?+ (\"empty\" | \"long\" | \"parse\" | \"short\")?+ \"objC\"? (\"DATA\" | \"Date\" | \"new\" | \"return\" | \"test\")?+ \"objA\"? \"i\"?+ \"catch\"? \"_err\"? \"_e\"? \"any\"? \"e\"?", + "mdl_score": 5095520, + "imports": [ + "import Benchmark from \"benchmark\";", + "import { z } from \"zod/v3\";", + "import type Benchmark from \"benchmark\";", + "import datetimeBenchmarks from \"./datetime.js\";", + "import discriminatedUnionBenchmarks from \"./discriminatedUnion.js\";", + "import ipv4Benchmarks from \"./ipv4.js\";", + "import objectBenchmarks from \"./object.js\";", + "import primitiveBenchmarks from \"./primitives.js\";", + "import realworld from \"./realworld.js\";", + "import stringBenchmarks from \"./string.js\";", + "import unionBenchmarks from \"./union.js\";", + "import { Mocker } from \"../tests/Mocker.js\";" + ], + "arg_patterns": { + "new": { + "occurrences": 29, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 23, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "manual": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Error": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Date": { + "occurrences": 21, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Mocker": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Set": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "str": { + "occurrences": 8, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 8, + "args": 0, + "types": [] + } + ] + }, + "num": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "fn": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "array": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + } + } + }, + { + "label": "packages/zod/src/v3/helpers", + "method_count": 31, + "imports": [ + "import type { IssueData, ZodErrorMap, ZodIssue } from \"../ZodError.js\";", + "import { getErrorMap } from \"../errors.js\";", + "import defaultErrorMap from \"../locales/en.js\";", + "import type { ZodParsedType } from \"./util.js\";" + ], + "arg_patterns": { + "map": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "getErrorMap": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "makeIssue": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "objectKeys": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "checker": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "objectValues": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Error": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "new": { + "occurrences": 1, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 1, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "packages/zod/src/v3/tests", + "method_count": 985, + "algorithm": "CRX", + "grammar": "root ::= (\"any\" | \"as\" | \"assertEqual\" | \"await\" | \"catch\" | \"data\" | \"expect\" | \"f\" | \"if\" | \"new\" | \"number\" | \"object\" | \"parse\" | \"result\" | \"return\" | \"safeParse\" | \"schema\" | \"string\" | \"toBe\" | \"toEqual\" | \"toThrow\" | \"typeof\" | \"util\" | \"val\" | \"z\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { expect, test } from \"vitest\";", + "import * as z from \"zod/v3\";", + "import { util } from \"../helpers/util.js\";", + "import { test } from \"vitest\";", + "import { z } from \"zod/v3\";", + "import { ZodError, ZodIssueCode } from \"../ZodError.js\";", + "import { ZodParsedType } from \"../helpers/util.js\";", + "import type { ZodFirstPartySchemaTypes, ZodFirstPartyTypeKind } from \"zod/v3\";", + "import { ZodIssueCode } from \"zod/v3\";", + "import { Mocker } from \"./Mocker.js\";", + "import { type SyncParseReturnType, isAborted, isDirty, isValid } from \"../helpers/parseUtil.js\";", + "import { ZodNullable, ZodOptional } from \"zod/v3\";", + "import { ZodIssueCode } from \"../ZodError.js\";", + "import type { StandardSchemaV1 } from \"../standard-schema.js\";", + "import { Buffer } from \"node:buffer\";", + "import { ZodError } from \"../ZodError.js\";" + ], + "arg_patterns": { + "expect": { + "occurrences": 2458, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 1706, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 458, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 252, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 34, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "test": { + "occurrences": 1002, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 994, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 8, + "args": 2, + "types": [ + "template", + "other" + ] + } + ] + }, + "isDirty": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isValid": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isAborted": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Array": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "new": { + "occurrences": 98, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 35, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 30, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 26, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 3, + "types": [ + "lit", + "lit", + "lit" + ] + } + ] + }, + "BigInt": { + "occurrences": 140, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 124, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 14, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ZodError": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Map": { + "occurrences": 27, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "Symbol": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Set": { + "occurrences": 93, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 78, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 9, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Number": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 15, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Error": { + "occurrences": 69, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 36, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Date": { + "occurrences": 78, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 42, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 9, + "args": 3, + "types": [ + "lit", + "lit", + "lit" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "getRandomInt": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "String": { + "occurrences": 15, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "doStuff": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "makeJwt": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 10, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "checker": { + "occurrences": 8, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + }, + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "parsed": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "invalidFuncInstance": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "func": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "myFunc": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "validFunc2Instance": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "callback": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "predicate": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "checkErrors": { + "occurrences": 32, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 28, + "args": 2, + "types": [ + "call", + "lit" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "stripOuter": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "Mocker": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "Test": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "Subtest": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "Bar": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "base": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "validatedFunction": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/classic", + "method_count": 409, + "algorithm": "CRX", + "grammar": "root ::= (\"$ZodType\" | \"ZodStringFormat\" | \"ZodType\" | \"any\" | \"args\" | \"as\" | \"check\" | \"checks\" | \"core\" | \"ctx\" | \"def\" | \"if\" | \"init\" | \"inst\" | \"json\" | \"new\" | \"normalizeParams\" | \"params\" | \"processJSONSchema\" | \"processors\" | \"return\" | \"util\" | \"value\")+", + "mdl_score": 1000000000000, + "imports": [ + "import * as core from \"../core/index.js\";", + "import * as schemas from \"./schemas.js\";", + "import type { ZodType } from \"./schemas.js\";", + "import { $ZodError } from \"../core/index.js\";", + "import * as util from \"../core/util.js\";", + "import type * as JSONSchema from \"../core/json-schema.js\";", + "import { type $ZodRegistry, globalRegistry } from \"../core/registries.js\";", + "import * as _checks from \"./checks.js\";", + "import * as _iso from \"./iso.js\";", + "import * as _schemas from \"./schemas.js\";", + "import type { ZodNumber, ZodString, ZodType } from \"./schemas.js\";", + "import { ZodISODate, ZodISODateTime, ZodISODuration, ZodISOTime } from \"./schemas.js\";", + "import { util } from \"../core/index.js\";", + "import * as processors from \"../core/json-schema-processors.js\";", + "import type { StandardSchemaWithJSONProps } from \"../core/standard-schema.js\";", + "import { createStandardJSONSchemaMethod, createToJSONSchemaMethod } from \"../core/to-json-schema.js\";", + "import * as checks from \"./checks.js\";", + "import * as parse from \"./parse.js\";" + ], + "arg_patterns": { + "exactOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "createStandardJSONSchemaMethod": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "ZodPipe": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "number": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "optional": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodDefault": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodSuccess": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "int": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "unknown": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "ZodPreprocess": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodTemplateLiteral": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "nullable": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "nonoptional": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodExactOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodRecord": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "transform": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Set": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "never": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "array": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "tuple": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodPrefault": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "BigInt": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "ZodDiscriminatedUnion": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Error": { + "occurrences": 45, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 21, + "args": 1, + "types": [ + "template" + ] + } + ] + }, + "Date": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodSet": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "createToJSONSchemaMethod": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "_installLazyMethods": { + "occurrences": 10, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 10, + "args": 3, + "types": [ + "var", + "lit", + "other" + ] + } + ] + }, + "union": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_enum": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "ZodIntersection": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "intersection": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodObject": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "pipe": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "call" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodUnion": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodCustom": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_catch": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodEnum": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodReadonly": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "prefault": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodLiteral": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "fn": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodCodec": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodTransform": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodXor": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMap": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "readonly": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodPromise": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodTuple": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodNullable": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodCatch": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodLazy": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "refine": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "ZodFunction": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "record": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "var" + ] + } + ] + }, + "lazy": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "string": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_default": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodNonOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "superRefine": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "boolean": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "WeakMap": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "_null": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "new": { + "occurrences": 67, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 44, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 7, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 4, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "convertSchema": { + "occurrences": 32, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 8, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "resolveRef": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "RegExp": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "convertBaseSchema": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Map": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "detectVersion": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/classic/tests", + "method_count": 2342, + "algorithm": "CRX", + "grammar": "root ::= (\"a\" | \"as\" | \"expect\" | \"expectTypeOf\" | \"if\" | \"new\" | \"number\" | \"object\" | \"optional\" | \"parse\" | \"result\" | \"return\" | \"safeParse\" | \"schema\" | \"string\" | \"toBe\" | \"toEqual\" | \"toEqualTypeOf\" | \"toMatchInlineSnapshot\" | \"toThrow\" | \"typeof\" | \"val\" | \"z\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { expect, expectTypeOf, test } from \"vitest\";", + "import * as z from \"zod/v4\";", + "import { expectTypeOf, test } from \"vitest\";", + "import { expect, test } from \"vitest\";", + "import { z } from \"zod/v4\";", + "import { describe, expect, expectTypeOf, test } from \"vitest\";", + "import { checkSync } from \"recheck\";", + "import { describe, expect, it } from \"vitest\";", + "import * as z from \"../index.js\";", + "import { inspect } from \"node:util\";", + "import { File as WebFile } from \"@web-std/file\";", + "import { afterEach, beforeEach, expect, expectTypeOf, test } from \"vitest\";", + "import type * as core from \"zod/v4/core\";", + "import { type infer as _infer, json, nullable, object, pipe, transform } from \"../../mini/index.js\";", + "import type { _ZodMiniJSONSchema } from \"../../mini/schemas.js\";", + "import { fromJSONSchema } from \"../from-json-schema.js\";", + "import { afterEach, expect, test } from \"vitest\";", + "import * as core from \"zod/v4/core\";", + "import { type ZodCustomStringFormat, hash } from \"zod\"; // adjust path as needed", + "import type { util } from \"zod/v4/core\";", + "import { randomBytes } from \"node:crypto\";", + "import { describe, expect, test } from \"vitest\";", + "import { Validator } from \"@seriousme/openapi-schema-validator\";", + "import * as z from \"zod\";" + ], + "arg_patterns": { + "expect": { + "occurrences": 6432, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3644, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2092, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 568, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 100, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 24, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "test": { + "occurrences": 2178, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 2174, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "lit", + "other", + "lit" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "template", + "other" + ] + } + ] + }, + "Error": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 9, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "template" + ] + } + ] + }, + "new": { + "occurrences": 214, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 106, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 42, + "args": 0, + "types": [] + }, + { + "count": 36, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 14, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 8, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "Date": { + "occurrences": 183, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 84, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 57, + "args": 0, + "types": [] + }, + { + "count": 30, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "base": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "resolve": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "setTimeout": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "BigInt": { + "occurrences": 180, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 162, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 14, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Promise": { + "occurrences": 9, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Set": { + "occurrences": 174, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 153, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 15, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "expectTypeOf": { + "occurrences": 790, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 728, + "args": 0, + "types": [] + }, + { + "count": 26, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 20, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 16, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Symbol": { + "occurrences": 39, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 24, + "args": 0, + "types": [] + }, + { + "count": 15, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Map": { + "occurrences": 120, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 108, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 12, + "args": 0, + "types": [] + } + ] + }, + "Uint8Array": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "stringToBoolean": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "TextDecoder": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "utf8ToBytes": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Number": { + "occurrences": 54, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 42, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "stringToBigInt": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "bytesToUtf8": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "decodeURIComponent": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "epochMillisToDate": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "encodeURIComponent": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "uriComponent": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "base64": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "stringToHttpURL": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "URL": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "stringToNumber": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "stringToURL": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "numberToBigInt": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "jsonCodec": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "hexToBytes": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "stringToInt": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "TextEncoder": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "epochSecondsToDate": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "base64urlToBytes": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "isoDatetimeToDate": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "createSortItemSchema": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "validateOpenAPI30Schema": { + "occurrences": 14, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 14, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "describe": { + "occurrences": 52, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 50, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Validator": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "String": { + "occurrences": 63, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 51, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "it": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "parse": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "validatedFunction": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "checkSync": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "hash": { + "occurrences": 36, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 24, + "args": 2, + "types": [ + "var", + "other" + ] + }, + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "createHash": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "toB64Url": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "makeDigests": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Array": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "File": { + "occurrences": 24, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 16, + "args": 2, + "types": [ + "other", + "lit" + ] + }, + { + "count": 8, + "args": 3, + "types": [ + "other", + "lit", + "other" + ] + } + ] + }, + "afterEach": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "beforeEach": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "RegExp": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "makeJwt": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 10, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "randomBytes": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "nest": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "createV4Schema": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "stripOuter": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "other" + ] + } + ] + }, + "opt": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "refine": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "lit" + ] + } + ] + }, + "detached": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "arr": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "nul": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "max": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "pick": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "omit": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "min": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "safeParse": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "partial": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "extend": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "positive": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "branded": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "A": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Bar": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Subtest": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "Test": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "parsed": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "fn": { + "occurrences": 4, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 4, + "args": 0, + "types": [] + } + ] + }, + "func": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "typeGuard": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "checker": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "validFunc2Instance": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "validFunc3Instance": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "json": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "object": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "pipe": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "call" + ] + } + ] + }, + "nullable": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "transform": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "doStuff": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "protoInput": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "makeZodObj": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "expectMethodMatch": { + "occurrences": 176, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 144, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 22, + "args": 2, + "types": [ + "call", + "other" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "other" + ] + } + ] + }, + "inspect": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "fromJSONSchema": { + "occurrences": 156, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 116, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 28, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "StringSchema": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/core", + "method_count": 704, + "algorithm": "CRX", + "grammar": "root ::= (\"$ZodType\" | \":\" | \"?\" | \"Class\" | \"Error\" | \"Object\" | \"Promise\" | \"Set\" | \"_ctx\" | \"any\" | \"as\" | \"checks\" | \"core\" | \"ctx\" | \"def\" | \"else\" | \"for\" | \"if\" | \"init\" | \"input\" | \"inst\" | \"instanceof\" | \"iss\" | \"key\" | \"map\" | \"new\" | \"normalizeParams\" | \"of\" | \"params\" | \"parse\" | \"payload\" | \"push\" | \"regexes\" | \"result\" | \"return\" | \"run\" | \"schema\" | \"schemas\" | \"then\" | \"throw\" | \"typeof\" | \"util\" | \"value\")+", + "mdl_score": 1000000000000, + "imports": [ + "import * as checks from \"./checks.js\";", + "import type * as core from \"./core.js\";", + "import type * as errors from \"./errors.js\";", + "import * as registries from \"./registries.js\";", + "import * as schemas from \"./schemas.js\";", + "import * as util from \"./util.js\";", + "import * as core from \"./core.js\";", + "import * as regexes from \"./regexes.js\";", + "import type * as schemas from \"./schemas.js\";", + "import type { Class } from \"./util.js\";", + "import type { $ZodCheck, $ZodStringFormats } from \"./checks.js\";", + "import { $constructor } from \"./core.js\";", + "import type { $ZodType } from \"./schemas.js\";", + "import type { StandardSchemaV1 } from \"./standard-schema.js\";", + "import { allProcessors } from \"./json-schema-processors.js\";", + "import type * as JSONSchema from \"./json-schema.js\";", + "import type { $ZodRegistry } from \"./registries.js\";", + "import {", + "import type * as checks from \"./checks.js\";", + "import { getEnumValues } from \"./util.js\";", + "import * as errors from \"./errors.js\";", + "import type { $ZodTypeDiscriminable } from \"./api.js\";", + "import { Doc } from \"./doc.js\";", + "import { parse, parseAsync, safeParse, safeParseAsync } from \"./parse.js\";", + "import type { ProcessParams, ToJSONSchemaContext } from \"./to-json-schema.js\";", + "import { version } from \"./versions.js\";", + "import type * as core from \"../core/index.js\";", + "import { type $ZodRegistry, globalRegistry } from \"./registries.js\";", + "import type { StandardJSONSchemaV1, StandardSchemaWithJSONProps } from \"./standard-schema.js\";", + "import { globalConfig } from \"./core.js\";", + "import type { $ZodConfig } from \"./core.js\";" + ], + "arg_patterns": { + "fn": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Definition": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "init": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "Set": { + "occurrences": 84, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 0, + "types": [] + }, + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 12, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "Symbol": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "initializer": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "new": { + "occurrences": 254, + "arg_count": { + "min": 0, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 126, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 39, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 33, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 31, + "args": 0, + "types": [] + }, + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "mapper": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "toDotPath": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "$constructor": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "lit", + "var", + "other" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "processError": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "String": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Class": { + "occurrences": 168, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 166, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_lt": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "_overwrite": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_Codec": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_String": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_gt": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "_gte": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "_check": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "_lte": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "var" + ] + } + ] + }, + "_Boolean": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "RegExp": { + "occurrences": 54, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 48, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 3, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "BigInt": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "handleCheckPropertyResult": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "other" + ] + } + ] + }, + "Error": { + "occurrences": 174, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 111, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 45, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 12, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "_safeEncodeAsync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_safeDecode": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_parseAsync": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_safeParseAsync": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_safeDecodeAsync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_encodeAsync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_safeEncode": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_safeParse": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_Err": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "_decodeAsync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_parse": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_encode": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_decode": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "WeakMap": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "Map": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 21, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "$ZodRegistry": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "registry": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "finalize": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "initializeContext": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "extractDefs": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 6, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "process": { + "occurrences": 54, + "arg_count": { + "min": 2, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 18, + "args": 3, + "types": [ + "other", + "other", + "other" + ] + }, + { + "count": 16, + "args": 3, + "types": [ + "other", + "other", + "var" + ] + }, + { + "count": 6, + "args": 3, + "types": [ + "var", + "other", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 4, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + } + ] + }, + "parse": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "Number": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "handleReadonlyResult": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "handlePipeResult": { + "occurrences": 8, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 8, + "args": 3, + "types": [ + "var", + "other", + "var" + ] + } + ] + }, + "runChecks": { + "occurrences": 6, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 6, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "parseAsync": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "handleArrayResult": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "handleSetResult": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "isObject": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "isValidBase64URL": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getTupleOptStart": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "handleCodecAResult": { + "occurrences": 8, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 8, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "handleCodecTxResult": { + "occurrences": 8, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 8, + "args": 4, + "types": [ + "var", + "var", + "other", + "var" + ] + } + ] + }, + "handleRefineResult": { + "occurrences": 4, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 4, + "args": 4, + "types": [ + "var", + "var", + "var", + "var" + ] + } + ] + }, + "Boolean": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Array": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "mergeValues": { + "occurrences": 6, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "subscript", + "subscript" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "handleUnionResults": { + "occurrences": 4, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 4, + "args": 4, + "types": [ + "other", + "var", + "var", + "var" + ] + } + ] + }, + "isValidJWT": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "handleDefaultResult": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "F": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "call" + ] + } + ] + }, + "normalizeDef": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "handleTupleResults": { + "occurrences": 4, + "arg_count": { + "min": 5, + "max": 5, + "common": 5 + }, + "patterns": [ + { + "count": 4, + "args": 5, + "types": [ + "var", + "var", + "var", + "var", + "var" + ] + } + ] + }, + "handleExclusiveUnionResults": { + "occurrences": 4, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 4, + "args": 4, + "types": [ + "other", + "var", + "var", + "var" + ] + } + ] + }, + "Doc": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isValidBase64": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "handleOptionalResult": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "first": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "handleMapResult": { + "occurrences": 4, + "arg_count": { + "min": 7, + "max": 7, + "common": 7 + }, + "patterns": [ + { + "count": 2, + "args": 7, + "types": [ + "other", + "other", + "var", + "var", + "var", + "var", + "var" + ] + }, + { + "count": 2, + "args": 7, + "types": [ + "var", + "var", + "var", + "var", + "var", + "var", + "var" + ] + } + ] + }, + "$ZodTuple": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "parseStr": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "handleCanaryResult": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "atob": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "handleCatchall": { + "occurrences": 4, + "arg_count": { + "min": 6, + "max": 6, + "common": 6 + }, + "patterns": [ + { + "count": 2, + "args": 6, + "types": [ + "var", + "var", + "var", + "var", + "other", + "var" + ] + }, + { + "count": 2, + "args": 6, + "types": [ + "other", + "var", + "var", + "var", + "var", + "var" + ] + } + ] + }, + "handleIntersectionResults": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "handleTupleResult": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "var", + "var" + ] + } + ] + }, + "handlePropertyResult": { + "occurrences": 8, + "arg_count": { + "min": 6, + "max": 6, + "common": 6 + }, + "patterns": [ + { + "count": 8, + "args": 6, + "types": [ + "var", + "var", + "var", + "var", + "var", + "var" + ] + } + ] + }, + "handleNonOptionalResult": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "safeParseAsync": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "fastpass": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "URL": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "template" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "_super": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "generateFastpass": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Date": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "safeParse": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "superParse": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "mergeDefs": { + "occurrences": 16, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 14, + "args": 2, + "types": [ + "other", + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "btoa": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "getter": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 18, + "args": 0, + "types": [] + } + ] + }, + "isPlainObject": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "clone": { + "occurrences": 14, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 14, + "args": 2, + "types": [ + "var", + "var" + ] + } + ] + }, + "unwrapMessage": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "assignProp": { + "occurrences": 14, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 14, + "args": 3, + "types": [ + "other", + "lit", + "var" + ] + } + ] + }, + "Uint8Array": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "stringifyPrimitive": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Proxy": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "other" + ] + } + ] + }, + "uint8ArrayToBase64": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "cached": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "base64ToUint8Array": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "flattenRef": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "subscript" + ] + } + ] + }, + "isTransforming": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 22, + "args": 2, + "types": [ + "other", + "var" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "call", + "var" + ] + } + ] + }, + "processor": { + "occurrences": 2, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 2, + "args": 4, + "types": [ + "var", + "var", + "var", + "var" + ] + } + ] + }, + "extractToDef": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "uriGenerator": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "createStandardJSONSchemaMethod": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "lit", + "other" + ] + } + ] + }, + "makeURI": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "getEnumValues": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "isSimpleIntersection": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "fixedBase64url": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "uuid": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "fixedBase64": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 10, + "args": 2, + "types": [ + "lit", + "lit" + ] + } + ] + }, + "timeSource": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/core/tests", + "method_count": 43, + "algorithm": "CRX", + "grammar": "root ::= (\"Object\" | \"any\" | \"anyConstructorSchema\" | \"array\" | \"defineProperty\" | \"enumSchema\" | \"expect\" | \"for\" | \"if\" | \"input\" | \"lazy\" | \"number\" | \"object\" | \"or\" | \"parse\" | \"record\" | \"result\" | \"result1\" | \"result2\" | \"safeParse\" | \"schema\" | \"string\" | \"stringSchema\" | \"testCase\" | \"toBe\" | \"toEqual\" | \"toThrow\" | \"tuple\" | \"y\" | \"z\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { expect, test } from \"vitest\";", + "import * as z from \"zod/v4\";", + "import { expect, expectTypeOf, test } from \"vitest\";", + "import * as z from \"zod/v3\";", + "import { describe, expect, it } from \"vitest\";" + ], + "arg_patterns": { + "expect": { + "occurrences": 90, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 50, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 24, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 10, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "it": { + "occurrences": 10, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 10, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "describe": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "test": { + "occurrences": 26, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 26, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "expectTypeOf": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/core/tests/locales", + "method_count": 85, + "algorithm": "CRX", + "grammar": "root ::= (\"BigInt\" | \"Date\" | \"Map\" | \"Set\" | \"TEST_CASES\" | \"array\" | \"arrayResult\" | \"arraySchema\" | \"bigint\" | \"boolean\" | \"cases\" | \"config\" | \"count\" | \"date\" | \"describe\" | \"el\" | \"email\" | \"endsWith\" | \"enum\" | \"error\" | \"es\" | \"expect\" | \"expected\" | \"for\" | \"function\" | \"hr\" | \"if\" | \"includes\" | \"input\" | \"it\" | \"localeError\" | \"max\" | \"min\" | \"multipleOf\" | \"new\" | \"number\" | \"numberResult\" | \"numberSchema\" | \"object\" | \"of\" | \"record\" | \"regex\" | \"result\" | \"safeParse\" | \"schema\" | \"set\" | \"setResult\" | \"startsWith\" | \"strict\" | \"string\" | \"stringResult\" | \"stringSchema\" | \"test\" | \"toBe\" | \"toContain\" | \"tuple\" | \"type\" | \"union\" | \"url\" | \"z\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { describe, expect, it } from \"vitest\";", + "import be from \"../../../locales/be.js\";", + "import { expect, test } from \"vitest\";", + "import { z } from \"../../../../index.js\";", + "import el from \"../../../locales/el.js\";", + "import { parsedType } from \"../../util.js\";", + "import es from \"../../../locales/es.js\";", + "import fr from \"../../../locales/fr.js\";", + "import { beforeEach, describe, expect, test } from \"vitest\";", + "import he from \"../../../locales/he.js\";", + "import hr from \"../../../locales/hr.js\";", + "import nl from \"../../../locales/nl.js\";", + "import ru from \"../../../locales/ru.js\";", + "import * as z from \"zod/v4\";" + ], + "arg_patterns": { + "fr": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "expect": { + "occurrences": 630, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 552, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 62, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 16, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "test": { + "occurrences": 116, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 116, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "Set": { + "occurrences": 24, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "new": { + "occurrences": 19, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 8, + "args": 0, + "types": [] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Map": { + "occurrences": 15, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "describe": { + "occurrences": 36, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 32, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "template", + "other" + ] + } + ] + }, + "localeError": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "it": { + "occurrences": 16, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 12, + "args": 2, + "types": [ + "lit", + "other" + ] + }, + { + "count": 4, + "args": 2, + "types": [ + "template", + "other" + ] + } + ] + }, + "BigInt": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 12, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "ru": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "hr": { + "occurrences": 8, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 8, + "args": 0, + "types": [] + } + ] + }, + "parsedType": { + "occurrences": 54, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 30, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 16, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Date": { + "occurrences": 12, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "Error": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "beforeEach": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "he": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "be": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "el": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "es": { + "occurrences": 10, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 10, + "args": 0, + "types": [] + } + ] + }, + "nl": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/locales", + "method_count": 214, + "algorithm": "CRX", + "grammar": "root ::= (\"$ZodInvalidTypeExpected\" | \"$ZodStringFormatIssues\" | \"$ZodStringFormats\" | \":\" | \"?\" | \"FormatDictionary\" | \"Record\" | \"Sizable\" | \"TypeDictionary\" | \"_issue\" | \"adj\" | \"as\" | \"case\" | \"default\" | \"errors\" | \"expected\" | \"function\" | \"getSizing\" | \"if\" | \"in\" | \"issue\" | \"joinValues\" | \"k\" | \"origin\" | \"parsedType\" | \"received\" | \"receivedType\" | \"return\" | \"sizing\" | \"string\" | \"stringifyPrimitive\" | \"switch\" | \"test\" | \"toString\" | \"util\")+ \"error\"?+", + "mdl_score": 1000000000000, + "imports": [ + "import type { $ZodStringFormats } from \"../core/checks.js\";", + "import type * as errors from \"../core/errors.js\";", + "import * as util from \"../core/util.js\";", + "import km from \"./km.js\";", + "import uk from \"./uk.js\";" + ], + "arg_patterns": { + "verbFor": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "getSizing": { + "occurrences": 200, + "arg_count": { + "min": 1, + "max": 4, + "common": 1 + }, + "patterns": [ + { + "count": 196, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 4, + "types": [ + "other", + "call", + "expr", + "lit" + ] + } + ] + }, + "typeLabel": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "error": { + "occurrences": 100, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 100, + "args": 0, + "types": [] + } + ] + }, + "withDefinite": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "typeEntry": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "getArmenianPlural": { + "occurrences": 4, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 4, + "args": 3, + "types": [ + "var", + "other", + "other" + ] + } + ] + }, + "withDefiniteArticle": { + "occurrences": 12, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 4, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "Number": { + "occurrences": 24, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 24, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "getUnitTypeFromNumber": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "capitalizeFirstCharacter": { + "occurrences": 10, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 10, + "args": 1, + "types": [ + "expr" + ] + } + ] + }, + "km": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "uk": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "getBelarusianPlural": { + "occurrences": 4, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 4, + "args": 4, + "types": [ + "var", + "other", + "other", + "other" + ] + } + ] + }, + "getRussianPlural": { + "occurrences": 4, + "arg_count": { + "min": 4, + "max": 4, + "common": 4 + }, + "patterns": [ + { + "count": 4, + "args": 4, + "types": [ + "var", + "other", + "other", + "other" + ] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/mini", + "method_count": 199, + "algorithm": "CRX", + "grammar": "root ::= (\"$ZodType\" | \":\" | \"?\" | \"ZodMiniStringFormat\" | \"ZodMiniType\" | \"any\" | \"as\" | \"core\" | \"def\" | \"init\" | \"innerType\" | \"inst\" | \"new\" | \"normalizeParams\" | \"params\" | \"return\" | \"schemas\" | \"typeof\" | \"util\")+", + "mdl_score": 1000000000000, + "imports": [ + "import * as core from \"../core/index.js\";", + "import * as schemas from \"./schemas.js\";", + "import * as util from \"../core/util.js\";", + "import * as parse from \"./parse.js\";" + ], + "arg_patterns": { + "ZodMiniMap": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Error": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 3, + "args": 1, + "types": [ + "template" + ] + } + ] + }, + "string": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "array": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodMiniRecord": { + "occurrences": 8, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 8, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniReadonly": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniDiscriminatedUnion": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniArray": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniUnion": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniLiteral": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "unknown": { + "occurrences": 6, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 6, + "args": 0, + "types": [] + } + ] + }, + "ZodMiniEnum": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniObject": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodMiniTransform": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "tuple": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniDefault": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniCodec": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_lazy": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "record": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "call", + "var" + ] + } + ] + }, + "ZodMiniOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "union": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniNullable": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniSuccess": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_null": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "optional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "custom": { + "occurrences": 2, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "other", + "var" + ] + } + ] + }, + "ZodMiniFunction": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "number": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "fn": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodMiniPromise": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "boolean": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "ZodMiniIntersection": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniTuple": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniSet": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "never": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "ZodMiniPipe": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniExactOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniLazy": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniXor": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniTemplateLiteral": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniPrefault": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "nullable": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "ZodMiniCatch": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "ZodMiniNonOptional": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "_enum": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "new": { + "occurrences": 38, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 35, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 1, + "args": 1, + "types": [ + "template" + ] + } + ] + } + } + }, + { + "label": "packages/zod/src/v4/mini/tests", + "method_count": 484, + "algorithm": "CRX", + "grammar": "root ::= (\"a\" | \"b\" | \"check\" | \"expect\" | \"expectTypeOf\" | \"new\" | \"number\" | \"output\" | \"parse\" | \"return\" | \"safeParse\" | \"schema\" | \"string\" | \"toBe\" | \"toEqual\" | \"toEqualTypeOf\" | \"toThrow\" | \"typeof\" | \"val\" | \"z\")+", + "mdl_score": 1000000000000, + "imports": [ + "import { expect, expectTypeOf, test } from \"vitest\";", + "import * as z from \"../index.js\";", + "import { test } from \"vitest\";", + "import * as z from \"zod/mini\";", + "import { expectTypeOf, test } from \"vitest\";", + "import { expect, test } from \"vitest\";", + "import { en } from \"zod/locales\";", + "import { util as zc } from \"zod/v4/core\";", + "import type { util } from \"zod/v4/core\";", + "import { z } from \"zod/mini\";", + "import type { StandardSchemaWithJSON } from \"../../core/standard-schema.js\";" + ], + "arg_patterns": { + "test": { + "occurrences": 340, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 340, + "args": 2, + "types": [ + "lit", + "other" + ] + } + ] + }, + "expect": { + "occurrences": 1256, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 712, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 460, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 62, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 20, + "args": 1, + "types": [ + "expr" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "acceptSchema": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "setTimeout": { + "occurrences": 4, + "arg_count": { + "min": 2, + "max": 2, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "lit" + ] + } + ] + }, + "String": { + "occurrences": 30, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Promise": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 6, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Number": { + "occurrences": 27, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 9, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Date": { + "occurrences": 54, + "arg_count": { + "min": 0, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 0, + "types": [] + }, + { + "count": 18, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 15, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "expectTypeOf": { + "occurrences": 186, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 158, + "args": 0, + "types": [] + }, + { + "count": 12, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 8, + "args": 1, + "types": [ + "call" + ] + } + ] + }, + "en": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "new": { + "occurrences": 41, + "arg_count": { + "min": 0, + "max": 3, + "common": 1 + }, + "patterns": [ + { + "count": 21, + "args": 1, + "types": [ + "other" + ] + }, + { + "count": 8, + "args": 0, + "types": [] + }, + { + "count": 6, + "args": 1, + "types": [ + "var" + ] + }, + { + "count": 5, + "args": 1, + "types": [ + "lit" + ] + }, + { + "count": 1, + "args": 3, + "types": [ + "other", + "lit", + "other" + ] + } + ] + }, + "doStuff": { + "occurrences": 6, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 4, + "args": 1, + "types": [ + "call" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Symbol": { + "occurrences": 18, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 15, + "args": 0, + "types": [] + }, + { + "count": 3, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "BigInt": { + "occurrences": 32, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 32, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "A": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "Map": { + "occurrences": 39, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 39, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "Set": { + "occurrences": 18, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 18, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "branded": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "lit" + ] + } + ] + }, + "File": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "other", + "lit", + "other" + ] + } + ] + } + } + }, + { + "label": "scripts", + "method_count": 6, + "imports": [ + "import { afterAll, beforeAll } from \"vitest\";", + "import { readdirSync, statSync, writeFileSync } from \"node:fs\";", + "import { join } from \"node:path\";" + ], + "arg_patterns": { + "statSync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "Set": { + "occurrences": 3, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 3, + "args": 0, + "types": [] + } + ] + }, + "readdirSync": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "writeStubPackageJsons": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 0, + "common": 0 + }, + "patterns": [ + { + "count": 2, + "args": 0, + "types": [] + } + ] + }, + "join": { + "occurrences": 8, + "arg_count": { + "min": 2, + "max": 3, + "common": 2 + }, + "patterns": [ + { + "count": 4, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 2, + "types": [ + "other", + "lit" + ] + }, + { + "count": 2, + "args": 3, + "types": [ + "var", + "var", + "lit" + ] + } + ] + }, + "findIndexJsFiles": { + "occurrences": 4, + "arg_count": { + "min": 1, + "max": 2, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 2, + "types": [ + "var", + "var" + ] + }, + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "writeFileSync": { + "occurrences": 2, + "arg_count": { + "min": 3, + "max": 3, + "common": 3 + }, + "patterns": [ + { + "count": 2, + "args": 3, + "types": [ + "var", + "var", + "lit" + ] + } + ] + }, + "new": { + "occurrences": 2, + "arg_count": { + "min": 0, + "max": 1, + "common": 0 + }, + "patterns": [ + { + "count": 1, + "args": 0, + "types": [] + }, + { + "count": 1, + "args": 1, + "types": [ + "template" + ] + } + ] + }, + "Error": { + "occurrences": 3, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 3, + "args": 1, + "types": [ + "template" + ] + } + ] + }, + "thrower": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "var" + ] + } + ] + }, + "afterAll": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + }, + "beforeAll": { + "occurrences": 2, + "arg_count": { + "min": 1, + "max": 1, + "common": 1 + }, + "patterns": [ + { + "count": 2, + "args": 1, + "types": [ + "other" + ] + } + ] + } + } + }, + { + "label": "(other)", + "method_count": 4, + "imports": [], + "arg_patterns": {} + } + ], + "total_methods": 6203 + }, + { + "language": ".js", + "conventions": [], + "total_methods": 0 + } +]