Orchestrata Ultimate › Tests › Reference › scripts › test_mine_prompt_history

Tests reference — tests/scripts/test_mine_prompt_history.py

Module of tests/scripts, split out because the directory page would be too large.

Prose pending.

tests/scripts/test_mine_prompt_history.py

source · 30 tests · 485 lines

Tests for scripts/mine_prompt_history.py — the Phase 5 (workflow-

Kind Name Line Description
function test_matched_markers_case_insensitive 38
function test_matched_markers_multiple_in_order 43
function test_matched_markers_none 49
function test_tokenize_strips_stopwords_and_punctuation 53
function test_filter_marker_prompts_keeps_only_hits 61
function test_cluster_by_signature_groups 71
function test_parse_rulings_index_extracts_rows 97
function test_parse_rulings_index_ignores_non_table_lines 107
function test_load_rulings_missing_dir_returns_empty 112
function test_load_rulings_reads_real_index 116
function test_match_ruling_finds_best_overlap 124
function test_match_ruling_below_min_overlap_returns_none 132
function test_grade_clusters_known_enforced 138
function test_grade_clusters_known_judgment_only 151
function test_grade_clusters_untracked 161
function test_grade_clusters_ranked_by_recurrence_count 172
function test_read_kimi_history_missing_dir_yields_nothing 190
function test_read_kimi_history_parses_content_field 194
function test_read_kimi_history_skips_malformed_lines 207
function test_read_claude_history_missing_file_yields_nothing 218
function test_read_claude_history_parses_display_and_timestamp 222
function test_read_claude_history_skips_blank_display 239
function test_render_report_includes_all_grade_sections 253
function test_write_report_creates_parent_dirs 281
function test_mine_without_kg_end_to_end 292
function test_query_kg_user_turns_finds_seeded_marker_turn 373
function test_mine_with_kg_includes_seeded_turn 386
function test_mine_kg_connection_failure_degrades_to_fallback_sources 409 A dead/unreachable KG must not abort the run -- fallback sources
function test_main_no_kg_writes_report 438
function test_main_subprocess_entrypoint_smoke 463