MCPcopy Create free account

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

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

Functionbanking_pedo_run
()
chapter5/permission-embedded-data-objects/pedo/eval/case_studies.py:56
Functionbanking_raw_run
Raw SQLite handler that follows the feature spec literally and does not encode the invariants. This is the canonical LLM-generated shape.
chapter5/permission-embedded-data-objects/pedo/eval/case_studies.py:167
Methodbase_action
(value: str, browser_session: BrowserSession)
chapter9/browser-use-rpa/browser-use/tests/ci/test_registry.py:331
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_radio_buttons.py:50
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_NavigateToUrlEvent.py:40
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_tools.py:66
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_GetDropdownOptionsEvent_aria_menus.py:121
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_ScrollEvent.py:58
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_tab_management.py:46
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_GetDropdownOptionsEvent.py:247
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_registry.py:80
Functionbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_ClickElementEvent.py:46
Methodbase_url
Return the base URL for the test HTTP server.
chapter9/browser-use-rpa/browser-use/tests/ci/test_registry_action_parameter_injection.py:57
Functionbaseline_agent
(inp)
tests/test_ch9_hermes_downstream_ablation.py:68
Functionbaseline_agent
(inp)
tests/test_ch8_hermes_downstream_ablation.py:68
Functionbaseline_agent
(input_data: Any)
chapter9/hermes-self-evolution/run_downstream_ablation.py:470
Functionbatch
(from, result)
tests/js/auto-translate.test.js:61
Methodbatch_rerank
Rerank multiple queries in batch. Args: queries: List of queries documents_list: List of document lists (one
chapter3/retrieval-pipeline/reranker.py:245
Methodbinary_classify
( self, instruction: str, text: str, examples: list[BinaryClassifyDatapoint] |
chapter2/prompt-engineering/tau_bench/model_utils/model/model.py:67
Methodbinary_classify
( self, instruction: str, text: str, examples: list[BinaryClassifyDatapoint] |
chapter2/prompt-engineering/tau_bench/model_utils/model/general_model.py:53
Methodbind_tools
(self, tools, **kwargs)
chapter5/agent-creator/deepagents_release_review.py:34
Functionblock_external_network
Fail fast if a unit test accidentally attempts a network connection.
chapter1/web-search-agent/tests/conftest.py:26
Methodblocked_count
(self)
chapter5/permission-embedded-data-objects/pedo/eval/dataguardbench/agentspec_baseline.py:98
Functionblocks_everything
(_p: str)
tests/test_ch2_prompt_injection_robustness.py:197
FunctionbookFootnotes
()
web-astro/src/lib/book-markdown.mjs:279
FunctionbookMarkdown
({ base = '/' } = {})
web-astro/src/lib/book-markdown.mjs:9
Functionboom_handler
(msg, ctx)
tests/test_ch4_notification_dispatcher.py:517
Functionbootstrap
()
scripts/book_figures/chapter5.py:126
Methodbrace_right
(self, x, y1, y2, label=None)
book-en/svg_lib.py:496
Methodbrace_right
(self, x, y1, y2, label=None)
book-tr/svg_lib.py:496
Methodbrace_right
(self, x, y1, y2, label=None)
book-ar/svg_lib.py:522
Methodbrace_right
(self, x, y1, y2, label=None)
book-ru/svg_lib.py:496
Methodbrace_right
(self, x, y1, y2, label=None)
book-es/svg_lib.py:496
Methodbrace_right
(self, x, y1, y2, label=None)
book-mn/svg_lib.py:497
Methodbrace_right
(self, x, y1, y2, label=None)
book-id/svg_lib.py:496
Methodbrowser_pid
Get the browser process ID.
chapter9/browser-use-rpa/browser-use/browser_use/browser/watchdogs/local_browser_watchdog.py:431
Methodbrowser_profile
Create and provide a BrowserProfile with headless mode.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_start.py:37
Methodbrowser_profile
(self)
chapter9/browser-use-rpa/browser-use/browser_use/agent/service.py:474
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_radio_buttons.py:56
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_NavigateToUrlEvent.py:46
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_tools.py:72
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_GetDropdownOptionsEvent_aria_menus.py:127
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_ScrollEvent.py:64
Functionbrowser_session
Create and provide a BrowserSession instance with a properly initialized tab.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_tab_management.py:52
Functionbrowser_session
()
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_take_screenshot.py:9
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_GetDropdownOptionsEvent.py:253
Functionbrowser_session
Create a real BrowserSession for testing
chapter9/browser-use-rpa/browser-use/tests/ci/test_registry.py:98
Functionbrowser_session
Create and provide a Browser instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_event_ClickElementEvent.py:52
Functionbrowser_session
Create a real browser session for testing
chapter9/browser-use-rpa/browser-use/tests/ci/conftest.py:158
Functionbrowser_session
Create a real browser session for testing.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_element_cache.py:61
Methodbrowser_session
Create a BrowserSession instance without starting it.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_start.py:43
Methodbrowser_session
Create a BrowserSession instance for event system testing.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_start.py:233
Methodbrowser_session
Create and provide a BrowserSession instance with security disabled.
chapter9/browser-use-rpa/browser-use/tests/ci/test_registry_action_parameter_injection.py:62
Methodbrowser_session
Create a clean BrowserSession for event testing.
chapter9/browser-use-rpa/browser-use/tests/ci/test_browser_session_tab_management.py:263
Functionbuild_binary_classify_prompts
( dps: list[BinaryClassifyDatapoint], suffix_strategy: PromptSuffixStrategy | None = None, )
chapter2/prompt-engineering/tau_bench/model_utils/model/chat.py:488
Functionbuild_binary_classify_prompts
( dps: list[BinaryClassifyDatapoint], include_response: bool = True, )
chapter2/prompt-engineering/tau_bench/model_utils/model/completion.py:401
Functionbuild_catalog
Build the tool catalog, optionally padded with distractor tools. Args: num_tools: Target total number of tools. 0 (default) keeps th
chapter4/active-tool-selection/benchmark.py:133
Functionbuild_client_and_model
构造客户端与模型名。端点、key 与模型名映射统一由 agentbook 的 provider 注册表维护。 chosen_by_reader=False 表示 "openai" 是本实验的默认值而非读者的显式选择: gpt-5.x 在有 OPENROUTER_API_KE
chapter5/conversational-ui/agent.py:42
Functionbuild_generate_prompts
(dps: list[GenerateDatapoint])
chapter2/prompt-engineering/tau_bench/model_utils/model/chat.py:570
Functionbuild_generate_prompts
( dps: list[GenerateDatapoint], include_response: bool = True )
chapter2/prompt-engineering/tau_bench/model_utils/model/completion.py:471
Functionbuild_historical_leaderboards_parallel
Build historical leaderboards using parallel processing. Args: df: Full voting DataFrame time_slices: List of (end_date,
chapter7/elo-leaderboard/parallel_processing.py:50
Functionbuild_indexes
()
chapter3/structured-index/api_service.py:155
Functionbuild_parse_force_prompts
( dps: list[ParseForceDatapoint], suffix_strategy: PromptSuffixStrategy | None = None, )
chapter2/prompt-engineering/tau_bench/model_utils/model/chat.py:545
Functionbuild_parse_force_prompts
( dps: list[ParseForceDatapoint], include_response: bool = True, )
chapter2/prompt-engineering/tau_bench/model_utils/model/completion.py:447
Functionbuild_parse_prompts
( dps: list[ParseDatapoint], suffix_strategy: PromptSuffixStrategy | None = None, )
chapter2/prompt-engineering/tau_bench/model_utils/model/chat.py:463
Functionbuild_parse_prompts
( dps: list[ParseDatapoint], include_response: bool = True, )
chapter2/prompt-engineering/tau_bench/model_utils/model/completion.py:381
Functionbuild_prompts
( dps: list[Datapoint], prompt_suffix_strategy: PromptSuffixStrategy | None )
chapter2/prompt-engineering/tau_bench/model_utils/model/chat.py:435
Functionbuild_score_prompts
( dps: list[ScoreDatapoint], suffix_strategy: PromptSuffixStrategy | None = None, )
chapter2/prompt-engineering/tau_bench/model_utils/model/chat.py:578
Functionbuild_score_prompts
( dps: list[ScoreDatapoint], include_response: bool = True, )
chapter2/prompt-engineering/tau_bench/model_utils/model/completion.py:484
Methodbuild_tree
Recursively build tree structure.
chapter4/execution-tools/filesystem_enhanced.py:248
Functionbuiltin_json_parser
内置的基础解析器:只认标准 JSON 行(JSON Lines)。 形如:{"timestamp": "...", "level": "INFO", "message": "..."} 不是 JSON,或不含基本字段,则返回 None(不是我的格式)。
chapter5/adaptive-log-parser/engine.py:36
Functioncache_call_w_dedup
(func: Callable[..., T])
chapter2/prompt-engineering/tau_bench/model_utils/api/cache.py:84
Methodcache_rate
(self)
chapter7/agent-cost-analysis/tracer.py:194
Functioncalculate
安全地计算一个纯数学表达式,例如 (949.5/352.1)**(1/2)-1 。
chapter10/multi-role-transfer/tools.py:172
MethodcalculateAudioDuration
(audioBuffer)
chapter6/live-audio/backend/server.js:622
Functioncalculate_pairwise_win_rates_chunk
Calculate win rates for a chunk of model pairs. Args: args: Tuple of (model_pairs, df) Returns: List of win
chapter7/elo-leaderboard/parallel_processing.py:99
Methodcalculate_reporting_completeness
( self, parent_org_unit: str, period: str )
chapter7/public-health-reporting-eval/reporting_tools.py:65
Methodcalculate_stats
Calculate min, max, mean, median for a list of values
chapter3/log-sanitization/metrics.py:79
Methodcalculate_test_positivity
(self, org_unit_id: str, period: str)
chapter7/public-health-reporting-eval/reporting_tools.py:53
Methodcalculate_win_probability
Calculate win probability using fast NumPy operations. Args: model_a: First model identifier model_b
chapter7/elo-leaderboard/optimized_elo.py:231
Functioncalculate_win_rate_matrix_from_data
Calculate empirical win rate matrix directly from vote data. Args: df: DataFrame with columns 'model_a', 'model_b', 'winner'
chapter7/elo-leaderboard/leaderboard.py:41
Functioncalculate_win_rate_matrix_parallel
Calculate win rate matrix using parallel processing. Args: df: DataFrame with match data models: List of models to inclu
chapter7/elo-leaderboard/parallel_processing.py:152
Functioncalendar_events
Get calendar events.
chapter4/perception-tools/src/main.py:690
Functioncall
发一次请求,返回原始 JSON;非 200 抛 :class:`ProviderError`。
chapter5/provider-failover/providers.py:57
Methodcall
()
chapter10/autonomous-phone-registration/webrtc_channel.py:247
Methodcall
()
chapter10/autonomous-phone-registration/webrtc_channel.py:315
Methodcall
()
chapter10/autonomous-phone-registration/webrtc_channel.py:423
Functioncall_judge
( comparison: dict[str, Any], *, endpoint: str, model: str, api_key: str, timeout: float )
chapter8/MiniMind-pretrain/validation/run_training_report_audit.py:326
Functioncall_judge
( retained: dict[str, Any], image: str, *, source_dir: Path, endpoint: str, model: str
chapter8/MiniMind-pretrain/validation/run_vlm_training_report_audit.py:450
Methodcalling_action
(message: str, browser_session: BrowserSession)
chapter9/browser-use-rpa/browser-use/tests/ci/test_registry.py:261
Functioncapture
把厂商的响应读成中立格式的一步。
chapter5/provider-failover/providers.py:88
Methodcapture_request
(request)
chapter9/browser-use-rpa/browser-use/tests/ci/test_sync_client_auth.py:331
Functioncatch_model_errors
(func: Callable[..., T])
chapter2/prompt-engineering/tau_bench/model_utils/api/sample.py:21
Methodcatches_by_cwe
Count pipeline catches per CWE ID.
chapter5/permission-embedded-data-objects/pedo/eval/dataguardbench/metrics.py:116
Methodcdp_client
Get the cached root CDP cdp_session.cdp_client. The client is created and started in self.connect().
chapter9/browser-use-rpa/browser-use/browser_use/browser/session.py:880
Methodcdp_client_for_target
(self, target_id: TargetID)
chapter9/browser-use-rpa/browser-use/browser_use/browser/session.py:2303
Methodcdp_url
CDP URL from browser profile.
chapter9/browser-use-rpa/browser-use/browser_use/browser/session.py:323
FunctionchangeLanguage
(n)
tests/js/auto-translate.test.js:47
Functionchar_error_rate
(reference: str, hypothesis: str)
chapter7/tts-quality-eval/pipeline.py:336
Functionchat
默认回声式回复;设置 CHAT_MODEL 后走真实 LLM 对话。 本实验聚焦"对话式 UI 定制",后端逻辑刻意保持最小; 如需真实客服体验,用 `python main.py --model <模型名>` 打开 LLM 模式即可。
chapter5/conversational-ui/backend/main.py:108
← previousnext →8,401–8,500 of 13,003, ranked by callers