MCPcopy Create free account

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

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

Methodtest_update_todo_list
Test updating an existing TODO list
chapter5/coding-agent/tests/test_todo_write_tool.py:34
Functiontest_upset_gives_larger_change
Test that unexpected results cause larger rating changes.
chapter7/elo-leaderboard/tests/test_elo.py:63
Functiontest_url_components
Test handling of URL components like credentials, ports, fragments, etc.
chapter9/browser-use-rpa/browser-use/tests/ci/test_agent_sensitive_data.py:189
Functiontest_urllib_network_detected
urllib usage is detected as a network call.
tests/test_ch5_sandbox_evaluator.py:102
Functiontest_usage_cost_uses_observed_cache_split
()
chapter10/staged-system-prompt/test_official_evidence.py:19
Functiontest_usage_none_does_not_crash
()
chapter4/active-tool-selection/tests/test_usage_none.py:39
Functiontest_usage_still_accumulated_when_present
()
chapter4/active-tool-selection/tests/test_usage_none.py:47
Methodtest_user_data_dir_not_allowed_to_corrupt_default_profile
Test user_data_dir handling for different browser channels and version mismatches.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_start.py:98
Functiontest_user_memory_agent_ignores_empty_choices_chunk
()
chapter3/user-memory/test_stream_empty_choices.py:51
Functiontest_uses_embedded_pricing_when_not_explicit
()
tests/test_ch6_cost_efficiency_analyzer.py:105
Functiontest_uses_embedded_pricing_when_not_explicit
()
tests/test_ch7_cost_efficiency_analyzer.py:105
Functiontest_vad_separates_acoustic_endpoint_from_600ms_decision
()
chapter6/streaming-speech/test_streaming.py:21
Functiontest_valid_arguments_still_call_tool
()
chapter4/multimodal-agent/test_execute_tool_robust.py:58
Functiontest_valid_data_length_stats_populated
(tmp_path)
tests/test_ch8_sft_data_auditor.py:78
Functiontest_valid_data_length_stats_populated
(tmp_path)
tests/test_ch7_sft_data_auditor.py:78
Functiontest_valid_data_passes_clean
(tmp_path)
tests/test_ch8_sft_data_auditor.py:66
Functiontest_valid_data_passes_clean
(tmp_path)
tests/test_ch7_sft_data_auditor.py:66
Functiontest_valid_item_still_works
A well-formed item still generates to its explicit output path.
chapter8/sesame/test_batch_inference.py:81
Functiontest_valid_json_still_returns_files
(tmp_path)
chapter5/conversational-ui/test_customize_malformed_json.py:29
Functiontest_valid_manifest_passes
()
chapter1/image-gen-workflow/tests/test_manifest_schema.py:54
Functiontest_valid_read_skill_still_works
()
chapter2/agent-skills-ppt/tests/test_dispatch.py:41
Functiontest_valid_result_still_full_score
()
chapter7/public-health-reporting-eval/tests/test_null_result.py:48
Methodtest_valid_status_values
Test all valid status values
chapter5/coding-agent/tests/test_todo_write_tool.py:79
Functiontest_valid_tool_call_still_works
(monkeypatch)
chapter10/multi-role-transfer/tests/test_tool_dispatch_errors.py:66
Functiontest_valid_tool_result_still_succeeds
()
chapter9/self-evolving-tools/test_tool_result_bad_json.py:24
Functiontest_validate_handles_none_case_arms
(tmp_path)
tests/test_ch9_validate_evidence_none_case.py:13
Functiontest_validate_handles_none_case_arms
(tmp_path)
tests/test_ch6_validate_evidence_none_case.py:13
Functiontest_validate_manifest_incomplete_route_allowed
()
chapter5/cad-vs-diffusion/test_offline.py:101
Functiontest_validate_manifest_missing_gate
()
chapter5/cad-vs-diffusion/test_offline.py:94
Functiontest_validate_manifest_ok
()
chapter5/cad-vs-diffusion/test_offline.py:90
Functiontest_validate_none_value_when_optional
()
tests/test_ch10_field_spec_validate_none.py:19
Functiontest_validate_none_value_when_required
()
tests/test_ch10_field_spec_validate_none.py:12
Functiontest_validate_options_with_none
()
tests/test_ch10_field_spec_validate_none.py:45
Functiontest_validate_valid_email_and_none_optional
()
tests/test_ch10_field_spec_validate_none.py:33
Functiontest_validate_whitespace_when_required
()
tests/test_ch10_field_spec_validate_none.py:26
Functiontest_validated_zero_is_numeric_but_not_the_false_sentinel
()
chapter10/generative-agents/tests/test_runner_helpers.py:55
Functiontest_validator_rejects
(store, writer_ctx)
chapter5/permission-embedded-data-objects/tests/test_core.py:96
Functiontest_validator_rejects_frozen_dataset_revision_tamper
( tmp_path: Path, monkeypatch: pytest.MonkeyPatch )
chapter8/MiniMind-pretrain/validation/test_training_report_audit.py:125
Functiontest_validator_rejects_modified_manifest_hash
(tmp_path: Path)
chapter10/autonomous-phone-registration/test_validate_acceptance.py:61
Functiontest_validator_rejects_raw_response_normalization_tamper
( tmp_path: Path, monkeypatch: pytest.MonkeyPatch )
chapter8/MiniMind-pretrain/validation/test_training_report_audit.py:96
Functiontest_validator_rejects_retained_output_request_binding_tamper
( tmp_path: Path, monkeypatch: pytest.MonkeyPatch )
chapter8/MiniMind-pretrain/validation/test_training_report_audit.py:112
Functiontest_validator_rejects_semantically_modified_normalized_decision
(tmp_path: Path)
chapter10/autonomous-phone-registration/test_validate_acceptance.py:49
Functiontest_validator_rejects_semantically_modified_raw_receipt
(tmp_path: Path)
chapter10/autonomous-phone-registration/test_validate_acceptance.py:37
Functiontest_validator_rejects_unbound_retained_artifact
(tmp_path: Path)
chapter10/autonomous-phone-registration/test_validate_acceptance.py:72
Functiontest_validator_requires_real_rollback_and_reentry
()
chapter10/staged-system-prompt/test_official_evidence.py:30
Functiontest_vector_dimension_mismatch_fallback
Verify dimension mismatch during vector comparison safely falls back to coverage score.
tests/test_ch3_hybrid_structured_retriever.py:291
Functiontest_verifier_requires_retained_media_artifacts
()
chapter6/phone-agent/test_verify_acceptance.py:47
Functiontest_video_index_excludes_stale_duplicate_outside_process_window
(tmp_path)
chapter7/openvla-robotwin2-eval/test_experiment.py:105
Functiontest_virtual_desktop_rejects_non_https
()
chapter4/execution-tools/test_gui_tools.py:10
Functiontest_virtual_mobile_rejects_unsafe_container_name
()
chapter4/execution-tools/test_gui_tools.py:16
Functiontest_virtual_terminal_reports_success_and_failure
(monkeypatch)
chapter4/execution-tools/test_execution_tools.py:104
Functiontest_vision_locate_missing_keys
模型省略 start/end → 按 -1 哨兵返回(走兜底逻辑),不抛 KeyError。
chapter5/video-edit/test_agents_llm_json.py:27
Functiontest_vision_locate_null_fields
模型返回显式 null → 同样按 -1 哨兵返回,不抛 TypeError。
chapter5/video-edit/test_agents_llm_json.py:36
Functiontest_visualization_code_writes_real_svg
(tmp_path)
chapter4/active-tool-discovery/test_exact_experiment.py:49
Functiontest_vlm_latest_pointer_does_not_overwrite_experiment_8_3
()
chapter8/MiniMind-pretrain/validation/test_vlm_training_report_audit.py:88
Methodtest_wait_action
Test that the wait action correctly waits for the specified duration.
chapter9/browser-use-rpa/browser-use/tests/ci/test_tools.py:150
Methodtest_wait_for_authorization
Test waiting for authorization with polling.
chapter9/browser-use-rpa/browser-use/tests/ci/test_sync_client_auth.py:193
Methodtest_wait_for_authorization_timeout
Test timeout during authorization waiting.
chapter9/browser-use-rpa/browser-use/tests/ci/test_sync_client_auth.py:256
Methodtest_walrus_and_if_expression_rejected
(self)
chapter1/context/tests/test_calc_sandbox.py:92
Functiontest_wasteful_takes_priority_over_cached
()
tests/test_ch6_cost_efficiency_analyzer.py:269
Functiontest_wasteful_takes_priority_over_cached
()
tests/test_ch7_cost_efficiency_analyzer.py:269
Functiontest_wasteful_turn_classification
()
tests/test_ch6_cost_efficiency_analyzer.py:231
Functiontest_wasteful_turn_classification
()
tests/test_ch7_cost_efficiency_analyzer.py:231
Methodtest_web_search_basic
Test Case 1: Basic web search
chapter1/search-codegen/tests/manual/agent_cases.py:45
Methodtest_web_search_with_analysis
Test Case 2: Web search with analysis request
chapter1/search-codegen/tests/manual/agent_cases.py:64
Functiontest_weighted_score_fusion_preserves_top_score_on_duplicate_doc_id
Verify weighted score fusion preserves top score when duplicate doc_ids exist in ranked list.
chapter3/retrieval-pipeline/test_weighted_fusion_dedup.py:4
Functiontest_whitespace_tests_field_loads_as_zero
(tmp_path)
chapter7/public-health-reporting-eval/tests/test_blank_csv_int.py:50
Functiontest_whole_wins_still_serialize
()
chapter7/elo-leaderboard/tests/test_animation_tie_wins.py:23
Functiontest_win_probability_symmetry
Test that win probabilities sum to 1.
chapter7/elo-leaderboard/tests/test_elo.py:107
Methodtest_windows_falls_back_to_comspec
(self)
chapter5/coding-agent/tests/test_shell_session.py:28
Methodtest_windows_prefers_powershell
(self)
chapter5/coding-agent/tests/test_shell_session.py:14
Functiontest_witch_killed_by_wolves_cannot_use_poison_in_same_night
Contract proved: Judge._witch_act prevents a Witch who was killed by wolves at night and not saved from using poison in the same night. Bug locked
chapter10/voice-werewolf/test_witch_killed_no_poison.py:7
Methodtest_without_randomization_is_not_a_transfer_claim
(self)
chapter6/rgb-sim2real-grasping/test_validator.py:16
Functiontest_wolf_vote_tie_consensus_selects_from_top_vote_getters
Regression test: Werewolf night vote tie-breaking must select from top vote-getters. When W1 votes for a 1-vote minority candidate (P1) while W2/W
tests/test_ch10_werewolf_wolf_vote_tie_consensus.py:14
Functiontest_word_boundary_reference_matching
()
tests/test_ch7_evaluate_multilingual.py:234
Functiontest_word_boundary_reference_matching
()
tests/test_ch8_evaluate_multilingual.py:234
Functiontest_worker_completing_after_winner_still_owes_ack
The expected ACK set is a snapshot taken when the winner settles.
chapter10/parallel-web-research/test_completed_worker_ack_regression.py:56
Functiontest_worker_completing_before_winner_is_not_reported_as_missing_ack
Contract proved: Coordinator.run excludes workers that completed with not_found or errors prior to target settlement from expected_loser_acks. Bug
chapter10/parallel-web-research/test_completed_worker_ack_regression.py:8
Functiontest_worker_exits_early_when_terminate_arrives_before_task_assigned
Contract proved: WorkerAgent handles terminate broadcast received before task_assigned without hanging or ignoring the signal. Bug locked out: inf
chapter10/parallel-web-research/test_worker_terminate_before_task.py:15
Functiontest_worker_failure_is_isolated_and_summarized_while_peer_completes
()
chapter10/parallel-web-research/test_coordination.py:79
Functiontest_working_backend_still_detects_pii
(tmp_path)
chapter3/log-sanitization/tests/test_sanitize_conversation.py:56
Functiontest_working_backend_with_structured_pii_items
(tmp_path)
chapter3/log-sanitization/tests/test_sanitize_conversation.py:65
Methodtest_working_directory_in_result
Test that working_directory is included in result
chapter5/coding-agent/tests/test_bash_tool.py:167
Methodtest_write_and_read_data
Test writing and reading Excel data.
chapter4/collaboration-tools/test_excel_tools.py:43
Methodtest_write_csv_file
Test writing CSV files.
chapter9/browser-use-rpa/browser-use/tests/ci/test_filesystem.py:392
Methodtest_write_file
Test writing content to files.
chapter9/browser-use-rpa/browser-use/tests/ci/test_filesystem.py:341
Methodtest_write_file
Test writing a file.
chapter4/execution-tools/test_terminal_controller.py:115
Methodtest_write_file_exception_handling
Test exception handling in write_file.
chapter9/browser-use-rpa/browser-use/tests/ci/test_filesystem.py:819
Functiontest_write_file_is_a_real_isolated_filesystem_mutation
(tmp_path: Path)
chapter2/prompt-injection/test_campaign.py:21
Functiontest_write_file_normal_content_unchanged
()
chapter10/staged-system-prompt/tests/test_null_tool_args.py:39
Functiontest_write_file_null_content_coerced_to_empty_string
()
chapter10/staged-system-prompt/tests/test_null_tool_args.py:25
Methodtest_write_json_file
Test writing JSON files.
chapter9/browser-use-rpa/browser-use/tests/ci/test_filesystem.py:367
Methodtest_write_search_edit_workflow
Test complete workflow: write, search, edit
chapter5/coding-agent/tests/test_integration.py:103
Methodtest_write_then_read_workflow
Test writing a file then reading it back
chapter5/coding-agent/tests/test_integration.py:78
Functiontest_wrong_arg_name_returns_error_string_not_crash
()
chapter10/multi-role-transfer/tests/test_tool_dispatch_errors.py:46
Methodtest_wrong_call_id_fails
(self)
chapter6/astra-async-steering/test_judging.py:46
Methodtest_wrong_call_id_fails
(self)
chapter6/astra-async-steering/validation/runs/exp6-14-20260905-formal/source/test_judging.py:46
Methodtest_wrong_model_fails_even_for_negative_control
(self)
chapter6/astra-async-steering/test_judging.py:70
Methodtest_wrong_model_fails_even_for_negative_control
(self)
chapter6/astra-async-steering/validation/runs/exp6-14-20260905-formal/source/test_judging.py:70
Functiontest_wrong_numeric_answer_loses_answer_points
()
chapter7/public-health-reporting-eval/tests/test_offline.py:30
← previousnext →12,701–12,800 of 13,003, ranked by callers