Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bojieli/ai-agent-book
/ functions
Functions
13,003 in github.com/bojieli/ai-agent-book
⨍
Functions
13,003
◇
Types & classes
1,574
↳
Endpoints
161
↓ 1 callers
Function
_env_names
(text: str)
chapter1/image-gen-workflow/tests/test_env_config.py:9
↓ 1 callers
Function
_env_or_default
Parse env var ``name`` with ``cast``; warn and fall back to ``default`` if malformed.
chapter4/collaboration-tools/src/subagent_tools.py:49
↓ 1 callers
Function
_equivalent
(actual: Any, expected: Any, tolerance: float)
chapter7/public-health-reporting-eval/evaluator.py:22
↓ 1 callers
Function
_error_type
(payload: Any)
chapter4/perception-tools/run_experiment_4_2.py:313
↓ 1 callers
Function
_esc
转义 drawtext/subtitles 文本中的特殊字符。
chapter5/video-edit/video_editor.py:27
↓ 1 callers
Method
_escape
(s)
extras/agent-lab/agent-trajectory.js:442
↓ 1 callers
Function
_escape_newlines
(src: str)
chapter9/browser-use-rpa/browser-use/examples/apps/news-use/news_monitor.py:118
↓ 1 callers
Function
_evaluate
(assertion: dict[str, Any], trajectory: dict[str, Any])
chapter5/log-diagnosis/campaign.py:303
↓ 1 callers
Method
_evaluate_condition
(self, accessor: AccessContext)
chapter5/permission-embedded-data-objects/run_live_security_eval.py:84
↓ 1 callers
Method
_evaluate_condition
(self, accessor: AccessContext)
chapter5/permission-embedded-data-objects/pedo/core/models.py:54
↓ 1 callers
Method
_evaluate_context_qa
Evaluate long context Q&A response
chapter3/memobase/locomo_benchmark.py:308
↓ 1 callers
Method
_evaluate_integration
Evaluate knowledge integration response
chapter3/memobase/locomo_benchmark.py:354
↓ 1 callers
Method
_evaluate_planning
Evaluate task planning response
chapter3/memobase/locomo_benchmark.py:332
↓ 1 callers
Method
_evaluate_predicate
(self, predicate: StatePredicate)
chapter9/browser-use-rpa/learning_agent/replay.py:180
↓ 1 callers
Method
_evaluate_reasoning
Evaluate multi-turn reasoning response
chapter3/memobase/locomo_benchmark.py:286
↓ 1 callers
Method
_evaluate_tool_usage
Evaluate tool usage response
chapter3/memobase/locomo_benchmark.py:374
↓ 1 callers
Function
_exact_topk
精确暴力最近邻(余弦),作为 ANN 召回率的 ground truth。
chapter3/dense-embedding/cli.py:263
↓ 1 callers
Function
_exec_pedo
(code: str, prompt: dict)
chapter5/permission-embedded-data-objects/pedo/eval/regeneration_robustness.py:191
↓ 1 callers
Function
_exec_raw
Execute generated raw-SQL code against fresh hiring DB. Return result dict.
chapter5/permission-embedded-data-objects/pedo/eval/regeneration_robustness.py:138
↓ 1 callers
Method
_exec_tool
执行工具,返回给 LLM 的文本结果。
chapter6/async-agent/runtime.py:312
↓ 1 callers
Method
_execute_actions
Execute the actions from model output
chapter9/browser-use-rpa/browser-use/browser_use/agent/service.py:757
↓ 1 callers
Method
_execute_click
Execute click action with smart waiting.
chapter9/browser-use-rpa/learning_agent/replay.py:323
↓ 1 callers
Method
_execute_history_step
Execute a single step from history with element validation
chapter9/browser-use-rpa/browser-use/browser_use/agent/service.py:1886
↓ 1 callers
Method
_execute_impl
Implement tool-specific logic Args: params: Tool input parameters Returns: Dict
chapter5/coding-agent/tools/base.py:87
↓ 1 callers
Method
_execute_input
Execute text input action.
chapter9/browser-use-rpa/learning_agent/replay.py:343
↓ 1 callers
Method
_execute_navigate
Execute navigation action.
chapter9/browser-use-rpa/learning_agent/replay.py:315
↓ 1 callers
Function
_execute_pedo
Execute generated code against the PEDO store.
chapter5/permission-embedded-data-objects/pedo/eval/dataguardbench/harness.py:607
↓ 1 callers
Function
_execute_raw
Execute generated code against raw PostgreSQL.
chapter5/permission-embedded-data-objects/pedo/eval/dataguardbench/harness.py:678
↓ 1 callers
Method
_execute_scroll
Execute scroll action.
chapter9/browser-use-rpa/learning_agent/replay.py:367
↓ 1 callers
Method
_execute_select
Execute select option action.
chapter9/browser-use-rpa/learning_agent/replay.py:359
↓ 1 callers
Method
_execute_single_tool
Execute one parsed tool call ({"name": ..., "arguments": ...}). Returns (result_text, is_error) with error messages formatted clearly
chapter2/local_llm_serving/agent.py:150
↓ 1 callers
Method
_execute_step
Execute a single workflow step. Args: step: The step to execute
chapter9/browser-use-rpa/learning_agent/replay.py:218
↓ 1 callers
Method
_execute_switch_tab
Execute tab switching (simplified for single tab replay).
chapter9/browser-use-rpa/learning_agent/replay.py:389
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result with detailed error information
chapter6/agent-with-event-trigger/agent.py:737
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result
chapter2/kv-cache/agent.py:587
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result with optional compression Args: tool_name: Name of the tool to execute
chapter2/context-compression/agent.py:189
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result with detailed error information Returns: Tuple of (result, error_detail, duration_m
chapter2/system-hint/agent.py:470
↓ 1 callers
Method
_execute_tool
Execute a browser-use tool.
chapter9/browser-use-rpa/browser-use/browser_use/mcp/server.py:442
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result Returns: Tuple of (result, error_message)
chapter3/user-memory/agent.py:402
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result
chapter3/contextual-retrieval/agent.py:101
↓ 1 callers
Method
_execute_tool
Execute a tool and return the result
chapter3/agentic-rag/agent.py:116
↓ 1 callers
Method
_execute_tool
Execute a tool and return results
chapter3/contextual-retrieval-for-user-memory/contextual_agent.py:208
↓ 1 callers
Method
_execute_tool_calls
Execute tool calls and return results. Multiple tool calls in the same turn are executed in parallel (they are independent by
chapter2/local_llm_serving/agent.py:96
↓ 1 callers
Method
_execute_upload
Execute file upload action.
chapter9/browser-use-rpa/learning_agent/replay.py:395
↓ 1 callers
Method
_execute_wait
Execute wait action.
chapter9/browser-use-rpa/learning_agent/replay.py:384
↓ 1 callers
Method
_execute_windows
Execute one Windows command while preserving logical session state.
chapter5/coding-agent/tools/shell_session.py:313
↓ 1 callers
Function
_expected_rule_ids
把人工标注的反馈来源映射到本次动态提炼出的规则 id。
chapter9/ai-style-skill/evaluate.py:22
↓ 1 callers
Function
_extent
Return (left, right) pixel extent of a text run of width w anchored at x.
book-en/svg_lib.py:175
↓ 1 callers
Function
_extent
Return (left, right) pixel extent of a text run of width w anchored at x.
book-tr/svg_lib.py:175
↓ 1 callers
Function
_extent
Return (left, right) pixel extent of a text run of width w anchored at x.
book-ar/svg_lib.py:191
↓ 1 callers
Function
_extent
Return (left, right) pixel extent of a text run of width w anchored at x.
book-ru/svg_lib.py:175
↓ 1 callers
Function
_extent
Return (left, right) pixel extent of a text run of width w anchored at x.
book-es/svg_lib.py:175
↓ 1 callers
Function
_extent
x дээр бэхэлсэн w өргөнтэй текстийн (зүүн, баруун) пикселийн хязгаарыг буцаана.
book-mn/svg_lib.py:175
↓ 1 callers
Function
_extent
Return (left, right) pixel extent of a text run of width w anchored at x.
book-id/svg_lib.py:175
↓ 1 callers
Function
_extract
(source: Path, timestamp: float, output: Path)
chapter5/video-edit/campaign.py:71
↓ 1 callers
Method
_extract_action_data
Extract action data for workflow capture. Args: action: The action object from browser-use result: T
chapter9/browser-use-rpa/learning_agent/agent.py:147
↓ 1 callers
Method
_extract_audio_to_text
Extract audio to text transcript
chapter4/multimodal-agent/agent.py:721
↓ 1 callers
Method
_extract_body
Extract email body from payload
chapter9/browser-use-rpa/browser-use/browser_use/integrations/gmail/service.py:209
↓ 1 callers
Method
_extract_content
Extract content from current page.
chapter9/browser-use-rpa/browser-use/browser_use/mcp/server.py:798
↓ 1 callers
Function
_extract_doc_id
Pull the document id out of a single result dict.
chapter3/retrieval-pipeline/stage_evaluator.py:51
↓ 1 callers
Function
_extract_experiment_name
Recover the ablation name from a result filename. Filenames follow the pattern produced by run_ablation.py: ``{strategy}-{model}-{ab
chapter2/prompt-engineering/analyze_results.py:16
↓ 1 callers
Method
_extract_extension
Extract .crx file to directory.
chapter9/browser-use-rpa/browser-use/browser_use/browser/profile.py:1002
↓ 1 callers
Method
_extract_final_answer
Extract text after FINAL ANSWER: if present; otherwise None.
chapter1/context/agent.py:697
↓ 1 callers
Method
_extract_images
Extract images from message content.
chapter9/browser-use-rpa/browser-use/browser_use/llm/ollama/serializer.py:39
↓ 1 callers
Method
_extract_intel_instructions
Extract and format Intel x86/x64 instructions.
chapter3/structured-index/document_processor.py:131
↓ 1 callers
Function
_extract_json
从模型回复里稳健地抽取 JSON(容忍 ```json 代码块或前后多余文字)。
chapter5/paper-to-ppt/agents.py:184
↓ 1 callers
Function
_extract_json
(text: str)
chapter9/self-modifying-agent/llm_generator.py:17
↓ 1 callers
Function
_extract_json
(text: str)
chapter9/browser-use-rpa/run_experiment_9_5.py:100
↓ 1 callers
Function
_extract_json
(text: str)
chapter9/harness-safety-gate/llm_generator.py:22
↓ 1 callers
Function
_extract_json
从模型回复里抽取第一个 JSON 对象。
chapter4/active-tool-discovery/agent.py:87
↓ 1 callers
Function
_extract_json
(text: str)
chapter4/active-tool-discovery/offline_backend.py:123
↓ 1 callers
Function
_extract_json_object
(text: str)
chapter7/android-world/run_controlled_experiment.py:820
↓ 1 callers
Method
_extract_page_statistics
Extract high-level page statistics from DOM tree for LLM context
chapter9/browser-use-rpa/browser-use/browser_use/agent/prompts.py:116
↓ 1 callers
Function
_extract_ranked_ids
Turn a list of result dicts into an ordered list of document ids. Ordering priority: an explicit ``rank`` field (ascending), then an explicit
chapter3/retrieval-pipeline/stage_evaluator.py:63
↓ 1 callers
Function
_extract_result
Extract text content from MCP result.
chapter4/collaboration-tools/quickstart.py:149
↓ 1 callers
Method
_extract_section_info
Extract section/chapter/article information from legal text
chapter3/agentic-rag/index_local_laws.py:242
↓ 1 callers
Method
_extract_select_options
Extract option information from a select element.
chapter9/browser-use-rpa/browser-use/browser_use/dom/serializer/serializer.py:324
↓ 1 callers
Method
_extract_text_content
Extract text content from message content, ignoring images.
chapter9/browser-use-rpa/browser-use/browser_use/llm/ollama/serializer.py:20
↓ 1 callers
Method
_extract_to_text
Extract multimodal content to text first
chapter4/multimodal-agent/agent.py:600
↓ 1 callers
Function
_extract_token_counts
(tu: Any)
chapter8/MultilingualReasoning/evaluate_multilingual.py:111
↓ 1 callers
Method
_extract_turns
Pull the list of turn dicts out of any supported trajectory shape.
chapter7/agent-cost-analysis/cost_efficiency_analyzer.py:252
↓ 1 callers
Method
_extract_url_from_task
Extract URL from task string using naive pattern matching.
chapter9/browser-use-rpa/browser-use/browser_use/agent/service.py:1359
↓ 1 callers
Function
_extract_value
Use the Phone Agent's LLM to turn a natural spoken answer into one value.
chapter10/autonomous-phone-registration/orchestration.py:29
↓ 1 callers
Function
_extract_vehicle_entities
从一批文本里通用地抽取车辆实体短语(不依赖具体用例)。
chapter3/agentic-rag-for-user-memory/offline_demo.py:69
↓ 1 callers
Method
_extract_visible_fields
Extracts the union of field names from a list of DataObjects or dicts.
chapter5/permission-embedded-data-objects/run_live_security_eval.py:399
↓ 1 callers
Function
_fact_label
Human-readable label for a gold fact (first variant for any-of facts).
chapter3/user-memory-evaluation/metrics.py:41
↓ 1 callers
Function
_fact_matched
Return True if the (possibly multi-variant) fact appears in the response.
chapter3/user-memory-evaluation/metrics.py:35
↓ 1 callers
Function
_factor_lines
(factors)
chapter3/structured-knowledge-extraction/extractor.py:22
↓ 1 callers
Function
_failure
( message: str, error_type: str, *, status_code: int | None = None, error_code: str | None
chapter4/perception-tools/src/xquik_tools.py:25
↓ 1 callers
Function
_fake_client
(content)
chapter5/video-edit/test_agents_llm_json.py:10
↓ 1 callers
Function
_fake_client
(responses)
tests/test_ch10_multi_role_transfer_unhashable_target.py:37
↓ 1 callers
Function
_fake_client
(responses)
chapter10/multi-role-transfer/tests/test_tool_dispatch_errors.py:31
↓ 1 callers
Function
_fallback_commit
()
scripts/site_source_paths.py:117
↓ 1 callers
Method
_fallback_extraction
Fallback extraction method if LLM is unavailable
chapter3/contextual-retrieval-for-user-memory/contextual_indexer.py:385
↓ 1 callers
Function
_fallback_google_search
Fallback to DuckDuckGo if Google API not available.
chapter4/perception-tools/src/google_search_enhanced.py:92
↓ 1 callers
Method
_fallback_llm_evaluation
Fallback LLM evaluation using direct API call when llm_evaluator module isn't available
chapter3/contextual-retrieval-for-user-memory/contextual_evaluator.py:565
↓ 1 callers
Function
_figure_html
(img: str, alt: str)
scripts/mkdocs_figure_captions.py:84
↓ 1 callers
Function
_filesystem
(name: str, query: str, options: dict[str, Any])
chapter4/perception-tools/src/expanded_catalog.py:696
↓ 1 callers
Method
_fill
(self, name: str, value: str)
chapter10/autonomous-phone-registration/orchestration.py:286
↓ 1 callers
Function
_fill_args
(tool_name: str)
chapter4/active-tool-discovery/offline_backend.py:107
← previous
next →
3,201–3,300 of 13,003, ranked by callers