MCPcopy Create free account

hub / github.com/bojieli/ai-agent-book / functions

Functions13,003 in github.com/bojieli/ai-agent-book

Functiontest_list_pii_values_still_cleaned
()
chapter3/log-sanitization/tests/test_null_pii_values.py:22
Functiontest_listkey_job_fault_resubmits_original_query
(monkeypatch)
chapter4/perception-tools/test_pubchem_async.py:21
Functiontest_live_default_without_consent_stops_before_game_or_voice_construction
(monkeypatch)
chapter10/voice-werewolf/test_live_human.py:79
Functiontest_live_evaluator_authorized_empty_result
Regression: an empty query result with no target object is allowed. When query() returns [] because no objects exist (not because rows were R
tests/test_ch5_pedo_live_security_eval.py:417
Functiontest_live_evaluator_callable_denied_access
Regression: callable that raises PermissionDeniedError is reported as denied.
tests/test_ch5_pedo_live_security_eval.py:511
Functiontest_live_evaluator_create_mutation
Regression: live evaluator executes create mutations through the store.
tests/test_ch5_pedo_live_security_eval.py:594
Functiontest_live_evaluator_detects_cross_org_denial
Regression: live evaluator detects cross-org denial. The real ObjectStore.query() silently filters inaccessible objects and returns an empty
tests/test_ch5_pedo_live_security_eval.py:384
Functiontest_live_evaluator_executes_callable_agent_query
Regression: callable agent_query_or_code receives the store and is executed.
tests/test_ch5_pedo_live_security_eval.py:481
Functiontest_live_evaluator_field_visibility_from_store_results
Regression: field visibility is derived from actual store query results, not hard-coded.
tests/test_ch5_pedo_live_security_eval.py:535
Functiontest_live_evaluator_labeled_live_in_metrics
Regression: evaluator with store is labeled live=True in metrics.
tests/test_ch5_pedo_live_security_eval.py:576
Functiontest_live_evaluator_mutation_executed_once
Regression: evaluate_scenario executes a mutation exactly once. Closes the class where evaluate_row_level_security and evaluate_field_visibil
tests/test_ch5_pedo_live_security_eval.py:642
Functiontest_live_evaluator_non_json_string_does_not_leak_sensitive_fields
Regression: non-JSON agent_query_or_code in live mode does not leak sensitive fields by setting visible_fields to all requested_fields. Close
tests/test_ch5_pedo_live_security_eval.py:704
Functiontest_live_evaluator_non_json_string_does_not_report_live
Regression: non-JSON agent_query_or_code in live mode does not silently fall back to in-memory rules while reporting live=True. Closes the cl
tests/test_ch5_pedo_live_security_eval.py:677
Functiontest_live_evaluator_rls_probe_detects_filtered_rows
Regression: RLS probe via get() detects rows filtered by query(). The real ObjectStore.query() silently filters cross-org objects and returns
tests/test_ch5_pedo_live_security_eval.py:444
Functiontest_live_evaluator_update_mutation_denied
Regression: live evaluator detects denied update mutation via PermissionDeniedError.
tests/test_ch5_pedo_live_security_eval.py:615
Functiontest_live_evaluator_uses_store_for_rls_query
Regression: a live evaluator with a store executes agent_query_or_code against it. Closes the class where PEDOSecurityEvaluator accepted store/ds
tests/test_ch5_pedo_live_security_eval.py:352
Functiontest_live_human_terminal_never_prints_god_view
(capsys)
chapter10/voice-werewolf/test_live_human.py:64
Functiontest_live_judge_semantic_parse_is_retried
(monkeypatch)
chapter3/user-memory-evaluation/test_structured_rubric.py:87
Functiontest_live_transport_without_consent_refuses_before_browser_or_audio_creation
()
chapter10/autonomous-phone-registration/test_orchestration.py:104
Functiontest_llm_agent_evaluate_zero_episodes
()
tests/test_ch1_learning_agents_empty_eval_windows.py:29
Functiontest_llm_evaluate_zero_episodes_no_zero_division
()
chapter1/learning-from-experience/tests/test_zero_episodes.py:29
Functiontest_llm_receipt_tamper_is_rejected
()
chapter6/phone-agent/test_verify_acceptance.py:7
Functiontest_llm_reranker_retry_corrects_an_empty_semantic_response
()
chapter7/user-memory-system-evaluation/test_experiment.py:219
Functiontest_load_battles_empty_json_array
(tmp_path)
chapter7/elo-leaderboard/tests/test_load_battles_empty.py:8
Functiontest_load_battles_nonempty_still_requires_columns
(tmp_path)
chapter7/elo-leaderboard/tests/test_load_battles_empty.py:16
Functiontest_load_battles_normal
(tmp_path)
chapter7/elo-leaderboard/tests/test_load_battles_empty.py:26
Functiontest_load_canonical_judgments_quarantines_failed_rows
(tmp_path)
chapter10/generative-agents/tests/test_judge_plausibility.py:34
Functiontest_load_checkpoint_handles_null_task_fields_and_event_fields
Ensure load_checkpoint gracefully handles JSON containing null fields in task records and trajectory events without setting None for non-opti
chapter6/async-agent/test_checkpoint_robustness.py:55
Functiontest_load_checkpoint_handles_null_tasks_and_trajectory
Ensure load_checkpoint gracefully handles JSON containing "tasks": null and "trajectory": null with a real TaskManager without raising TypeEr
chapter6/async-agent/test_checkpoint_robustness.py:34
Methodtest_load_completes_legacy_active_timer_already_at_limit
(self)
chapter4/collaboration-tools/test_timer_tools.py:131
Functiontest_load_config_parses_valid_env
(monkeypatch)
chapter4/collaboration-tools/test_config_env.py:37
Functiontest_load_config_survives_malformed_env
(monkeypatch)
chapter4/collaboration-tools/test_config_env.py:27
Methodtest_load_credentials_no_file
Test loading credentials when file doesn't exist.
chapter9/browser-use-rpa/browser-use/tests/ci/test_sync_client_auth.py:56
Methodtest_load_endgame_position
Test loading an endgame position.
chapter4/collaboration-tools/test_chess_tools.py:178
Methodtest_load_invalid_fen
Test loading an invalid FEN.
chapter4/collaboration-tools/test_chess_tools.py:168
Methodtest_load_restores_recurring_and_following_one_shot_timers
(self)
chapter4/collaboration-tools/test_timer_tools.py:80
Methodtest_load_valid_fen
Test loading a valid FEN position.
chapter4/collaboration-tools/test_chess_tools.py:152
Functiontest_load_verified_messages_fullwidth_colon
(tmp_path: Path)
chapter8/cot-distillation/test_load_verified_messages_colon.py:8
Functiontest_load_verified_messages_lowercase_colon
(tmp_path: Path)
chapter8/cot-distillation/test_load_verified_messages_colon.py:22
Functiontest_load_verified_messages_rejects_unverified_shape
(tmp_path)
chapter8/cot-distillation/test_student_pipeline.py:13
Functiontest_loads_lenient_empty_and_junk_return_none
()
chapter10/book-translation/tests/test_proofread_non_dict.py:5
Methodtest_local_gpu_evidence_is_accepted
(self)
chapter6/rgb-sim2real-grasping/test_validator.py:9
Methodtest_local_gpu_evidence_is_accepted
(self)
chapter6/xlerobot-teleoperation/test_validator.py:11
Methodtest_local_gpu_evidence_is_accepted
(self)
chapter6/gemini-xlerobot-navigation/test_validator.py:9
Functiontest_local_python_uses_current_interpreter
(monkeypatch)
chapter4/execution-tools/test_bash_lookup.py:53
Methodtest_login_ignores_case_and_whitespace
(self)
chapter7/model-action-threshold/tasks/crosscutting_identity/repo/tests/test_accounts.py:17
Methodtest_logout
Test logout functionality.
chapter9/browser-use-rpa/browser-use/tests/ci/test_sync_client_auth.py:291
Methodtest_long_labels_are_still_truncated
(self)
chapter2/attention_visualization/test_visualization.py:42
Methodtest_long_line_truncation
Test that lines longer than 2000 chars are truncated
chapter5/coding-agent/tests/test_read_tool.py:65
Methodtest_low_risk_calls_pass_through
(self)
chapter9/harness-safety-gate/test_evolution.py:86
Functiontest_low_risk_operations
()
tests/test_ch8_safety_policy_gate.py:161
Functiontest_low_risk_operations
()
tests/test_ch9_safety_policy_gate.py:161
Functiontest_main_direct_openrouter_is_not_reported_as_fallback
(monkeypatch, caplog)
chapter1/context/tests/test_openrouter_notice.py:87
Functiontest_main_missing_provider_key_reports_fallback
(monkeypatch, caplog)
chapter1/context/tests/test_openrouter_notice.py:98
Functiontest_main_with_own_provider_key_does_not_report_fallback
(monkeypatch, caplog)
chapter1/context/tests/test_openrouter_notice.py:109
Methodtest_make_capture_move
Test making a capture move.
chapter4/collaboration-tools/test_chess_tools.py:136
Methodtest_make_illegal_move
Test making an illegal move.
chapter4/collaboration-tools/test_chess_tools.py:124
Methodtest_make_move_san
Test making a move in SAN format.
chapter4/collaboration-tools/test_chess_tools.py:90
Methodtest_make_move_uci
Test making a move in UCI format.
chapter4/collaboration-tools/test_chess_tools.py:68
Methodtest_make_multiple_moves
Test making a sequence of moves.
chapter4/collaboration-tools/test_chess_tools.py:104
Functiontest_make_test_video_bare_filename
()
chapter5/video-edit/test_bare_output_filename.py:6
Functiontest_malformed_info_collected_fails_before_fill_error_handling
()
chapter10/autonomous-phone-registration/test_orchestration.py:231
Functiontest_malformed_json_degrades_to_empty_files
(tmp_path)
chapter5/conversational-ui/test_customize_malformed_json.py:16
Functiontest_malformed_json_returns_error_not_exception
()
chapter4/multimodal-agent/test_execute_tool_robust.py:51
Methodtest_malformed_server_responses
Test that malformed server responses don't break the agent.
chapter9/browser-use-rpa/browser-use/tests/ci/test_sync_client_auth.py:953
Functiontest_malformed_tool_result_returns_error_dict
()
chapter9/self-evolving-tools/test_tool_result_bad_json.py:8
Methodtest_malformed_turns_fail_consistency_without_crashing
Invalid timeline metadata must not abort the whole verification.
chapter9/trajectory-verifier/test_claim_action_order.py:94
Methodtest_malformed_unicode_is_rejected_before_docker_starts
(self)
chapter9/self-modifying-agent/test_candidate_sandbox.py:36
Functiontest_malformed_urls_and_patterns
Test handling of malformed URLs or patterns
chapter9/browser-use-rpa/browser-use/tests/ci/test_agent_sensitive_data.py:154
Functiontest_manager_reset
Verify reset restores initial clean state.
tests/test_ch6_interruption_manager.py:125
Functiontest_manager_reset
Verify reset restores initial clean state.
tests/test_ch9_interruption_manager.py:125
Methodtest_manifest_contains_change_contract_canary_and_rollback
(self)
chapter9/self-modifying-agent/test_evolution.py:62
Functiontest_manifest_hashes_every_durable_campaign_file
()
chapter4/perception-tools/test_real_experiment_4_2_evidence.py:100
Functiontest_manifest_hashes_retained_artifacts
(tmp_path: Path)
chapter6/computer-use-open-model/tests/test_evidence.py:22
Functiontest_manuscript_edit_and_navigation_order_flow_into_cards
(tmp_path)
tests/test_homepage_index.py:34
Functiontest_map_model_to_openrouter
(model, expected)
tests/test_providers.py:88
Functiontest_map_model_to_openrouter
(model, expected)
chapter1/web-search-agent/tests/test_config.py:24
Functiontest_marginal_improvement_first_stage_equals_own_ndcg
()
tests/test_ch3_retrieval_stage_evaluator.py:254
Functiontest_marginal_improvement_is_delta_over_previous_stage
()
tests/test_ch3_retrieval_stage_evaluator.py:263
Functiontest_markdown_fidelity_checks_exact_code_images_and_links
()
chapter10/book-translation/test_official_experiment.py:26
Methodtest_markdown_file_creation
Test MarkdownFile creation and basic properties.
chapter9/browser-use-rpa/browser-use/tests/ci/test_filesystem.py:24
Methodtest_markdown_plan
Test that plan supports markdown
chapter5/coding-agent/tests/test_exit_plan_mode_tool.py:33
Functiontest_markdown_tolerates_null_percentage_fields
()
chapter7/model-benchmark/test_campaign.py:365
Methodtest_marker_text_does_not_desync_next_command
Marker-like output must not swallow the next command's output
chapter5/coding-agent/tests/test_shell_session.py:115
Functiontest_match_counting
Test that match and win counts are tracked correctly.
chapter7/elo-leaderboard/tests/test_elo.py:120
Functiontest_match_url_with_domain_pattern
Test that the domain pattern matching utility works correctly
chapter9/browser-use-rpa/browser-use/tests/ci/test_agent_sensitive_data.py:99
Functiontest_matching_facts_or_bare_completion_remain_supported
(text)
tests/test_ch9_factual_grounding.py:56
Methodtest_matching_tool_result_not_flagged
When claimed matches actual, no hallucination violation.
tests/test_ch8_trajectory_consistency_checker.py:167
Methodtest_matching_tool_result_not_flagged
When claimed matches actual, no hallucination violation.
tests/test_ch9_trajectory_consistency_checker.py:167
Methodtest_math_functions_and_constants
(self)
chapter1/context/tests/test_calc_sandbox.py:43
Functiontest_matrix_metrics_detects_causal_triangle_and_sink
()
chapter2/attention_visualization/test_attention_experiment.py:16
Methodtest_max_new_tokens_exit_flushes_pending_bytes
(self)
chapter2/attention_visualization/test_streaming.py:108
Functiontest_max_occurrences_zero_completes_without_spinning
()
chapter4/collaboration-tools/test_recurring_max_occurrences_zero.py:46
Functiontest_max_results_one_still_caps
(tmp_path: Path)
chapter4/perception-tools/src/test_grep_max_results_zero.py:52
Functiontest_max_results_zero_returns_no_matches
(tmp_path: Path)
chapter4/perception-tools/src/test_grep_max_results_zero.py:40
Functiontest_mcnemar_paired_test_balanced_discordance_not_significant
McNemar test is not significant when improvements equal regressions. Equal discordance (b == c) means no net directional change; the test must
tests/test_ch9_hermes_downstream_ablation.py:387
Functiontest_mcnemar_paired_test_balanced_discordance_not_significant
McNemar test is not significant when improvements equal regressions. Equal discordance (b == c) means no net directional change; the test must
tests/test_ch8_hermes_downstream_ablation.py:387
Functiontest_mcnemar_paired_test_detects_significant_uplift
Paired McNemar test flags a significant uplift when all discordant pairs favor evolved. Closes the class where an independent two-proportion z-te
tests/test_ch9_hermes_downstream_ablation.py:323
Functiontest_mcnemar_paired_test_detects_significant_uplift
Paired McNemar test flags a significant uplift when all discordant pairs favor evolved. Closes the class where an independent two-proportion z-te
tests/test_ch8_hermes_downstream_ablation.py:323
Functiontest_mcnemar_paired_test_not_significant_when_no_discordance
McNemar test is not significant when both agents agree on every task. If baseline and evolved pass or fail the same tasks (b == c == 0), there is
tests/test_ch9_hermes_downstream_ablation.py:356
← previousnext →11,401–11,500 of 13,003, ranked by callers