MCPcopy Create free account

hub / github.com/crewAIInc/crewAI / functions

Functions12,753 in github.com/crewAIInc/crewAI

↓ 923 callersMethodappend
Append new training data for a specific agent and iteration. Args: train_iteration: The training iteration number. ag
lib/crewai/src/crewai/utilities/training_handler.py:19
↓ 696 callersMethodget
Retrieve an auth scheme by key.
lib/crewai/src/crewai/a2a/auth/utils.py:52
↓ 591 callersMethodkickoff
Execute the crew's workflow. Args: inputs: Optional input dictionary for task interpolation. input_files: Optional di
lib/crewai/src/crewai/crew.py:966
↓ 378 callersMethodjoin
(self)
lib/crewai/tests/test_flow_from_definition.py:225
↓ 190 callersMethodget
Sync wrapper for aget.
lib/crewai-files/src/crewai_files/cache/upload_cache.py:415
↓ 175 callersMethodemit
Emit an event to all registered handlers. If handlers have dependencies (registered with depends_on), they execute in dependency orde
lib/crewai/src/crewai/events/event_bus.py:572
↓ 136 callersMethodcall
High-level LLM call method. Args: messages: Input messages for the LLM. Can be a string or list of message d
lib/crewai/src/crewai/llm.py:1780
↓ 128 callersMethodfrom_declaration
Build a runnable declarative flow from contents or a file path.
lib/crewai/src/crewai/flow/runtime/__init__.py:479
↓ 118 callersMethodprint
Print to console. Simplified to only handle panel-based output.
lib/crewai/src/crewai/events/utils/console_formatter.py:183
↓ 114 callersMethodset
Store an auth scheme.
lib/crewai/src/crewai/a2a/auth/utils.py:47
↓ 100 callersMethodinvoke
Main method for tool execution.
lib/crewai/src/crewai/tools/structured_tool.py:340
↓ 100 callersMethodupdate
Update an existing memory record by ID. Args: record_id: ID of the record to update. content: New content; re-embedde
lib/crewai/src/crewai/memory/unified_memory.py:852
↓ 99 callersMethodextend
(self, tools: list[T])
lib/crewai-tools/src/crewai_tools/adapters/tool_collection.py:44
↓ 94 callersMethodprint
Print ``content`` with optional color, honoring suppression context.
lib/crewai-core/src/crewai_core/printer.py:78
↓ 91 callersMethodappend
(self, tool: T)
lib/crewai-tools/src/crewai_tools/adapters/tool_collection.py:40
↓ 86 callersMethodpop
(self, index: int = -1)
lib/crewai-tools/src/crewai_tools/adapters/tool_collection.py:57
↓ 80 callersMethodrun
Executes the tool synchronously. Args: *args: Positional arguments for the tool. **kwargs: Keyword arguments for the
lib/crewai/src/crewai/tools/base_tool.py:507
↓ 78 callersMethodscoped_handlers
Context manager for temporary event handling scope. Useful for testing or temporary event handling. All handlers registered within th
lib/crewai/src/crewai/events/event_bus.py:832
↓ 77 callersMethod_run
(self, question: str)
lib/crewai-tools/tests/base_tool_test.py:46
↓ 77 callersMethodread_text
Read the file content as string.
lib/crewai-files/src/crewai_files/core/types.py:214
↓ 73 callersMethodadd
( # type: ignore[override] self, content: str | Path, data_type: str | DataType | Non
lib/crewai-tools/src/crewai_tools/rag/core.py:80
↓ 72 callersMethodkeys
Return keys for dict unpacking.
lib/crewai-files/src/crewai_files/core/types.py:226
↓ 71 callersMethodinfo
Return scope info for path. Args: path: Scope path to get info for. If None and root_scope is set, defaults to ro
lib/crewai/src/crewai/memory/unified_memory.py:956
↓ 67 callersMethodkickoff
Execute the agent with the given messages using the AgentExecutor. This method provides standalone agent execution without requiring a Crew.
lib/crewai/src/crewai/agent/core.py:1522
↓ 64 callersMethodflush
Block until all pending event handlers complete. This method waits for all futures from previously emitted events to finish executing
lib/crewai/src/crewai/events/event_bus.py:734
↓ 64 callersMethodread
Read the file content as bytes.
lib/crewai-files/src/crewai_files/core/types.py:199
↓ 59 callersMethod_handle_action_event
Generic handler for action events (LLM calls, tool usage). Args: event_type: Type of the event. source: Source object
lib/crewai/src/crewai/events/listeners/tracing/trace_listener.py:891
↓ 59 callersFunction_make_tool
Return a NL2SQLTool wired to an in-memory SQLite DB. Schema-introspection is patched out so we can create the tool without a real PostgreSQL
lib/crewai-tools/tests/tools/test_nl2sql_security.py:23
↓ 59 callersMethodjson
(self)
lib/crewai/src/crewai/crews/crew_output.py:31
↓ 56 callersMethodacall
Async high-level LLM call method. Args: messages: Input messages for the LLM. Can be a string or list of mes
lib/crewai/src/crewai/llm.py:1919
↓ 55 callersMethodprint_panel
Print a panel with consistent formatting if verbose is enabled.
lib/crewai/src/crewai/events/utils/console_formatter.py:208
↓ 54 callersFunctioncreate_model_from_schema
Create a Pydantic model from a JSON schema. This function takes a JSON schema as input and dynamically creates a Pydantic model class based o
lib/crewai/src/crewai/utilities/pydantic_schema_utils.py:799
↓ 53 callersMethodakickoff
Native async kickoff method using async task execution throughout. Unlike kickoff_async which wraps sync kickoff in a thread, this method
lib/crewai/src/crewai/crew.py:1176
↓ 52 callersFunctionsanitize_tool_name
Sanitize tool name for LLM provider compatibility. Normalizes Unicode, splits camelCase, lowercases, replaces invalid characters with undersc
lib/crewai/src/crewai/utilities/string_utils.py:26
↓ 49 callersMethodadd
Add an event to the record and wire its edges. Args: event: The event to insert. Returns: The created node.
lib/crewai/src/crewai/state/event_record.py:110
↓ 48 callersMethodopen
(nodeName, metadata)
lib/crewai/src/crewai/flow/visualization/assets/interactive.js:1410
↓ 47 callersMethodget
(self, key: str, default: Any = None)
lib/crewai/src/crewai/utilities/prompts.py:17
↓ 44 callersMethod_validate_query
Raise ValueError if *sql_query* is not permitted under the current config. Splits the query on semicolons and validates each statement
lib/crewai-tools/src/crewai_tools/tools/nl2sql/nl2sql_tool.py:293
↓ 44 callersMethodcreate
(self, handle: str)
lib/cli/src/crewai_cli/tools/main.py:67
↓ 44 callersMethodformat
Format this match as a human-readable string including metadata. Returns: A multi-line string with score, content, categories, an
lib/crewai/src/crewai/memory/types.py:92
↓ 44 callersMethodrun
(executor: CrewAgentExecutor, expected: str)
lib/crewai/tests/agents/test_agent.py:2765
↓ 43 callersFunction_build_executor
Create an AgentExecutor without validation — for unit tests. Uses model_construct to skip Pydantic validators so plain Mock() objects are acc
lib/crewai/tests/agents/test_agent_executor.py:25
↓ 43 callersMethodlog
Log a message with timestamp if verbose mode is enabled. Args: level: The log level (e.g., 'info', 'warning', 'error').
lib/crewai/src/crewai/utilities/logger.py:17
↓ 42 callersMethodconnect
Connect to MCP server and initialize session. Returns: Self for method chaining. Raises: ConnectionError: If
lib/crewai/src/crewai/mcp/client.py:139
↓ 40 callersMethodslice
Retrieve a prompt slice by key. Args: slice: The key of the prompt slice to retrieve. Returns: The prompt sl
lib/crewai/src/crewai/utilities/i18n.py:56
↓ 39 callersMethodclear
Remove all nodes from the record under the write lock.
lib/crewai/src/crewai/state/event_record.py:214
↓ 39 callersMethodflow_definition
Return the static Flow Definition built from this Flow class.
lib/crewai/src/crewai/flow/runtime/__init__.py:470
↓ 39 callersMethodresolve
Convert MCP server references/configs to CrewAI tools.
lib/crewai/src/crewai/mcp/tool_resolver.py:68
↓ 37 callersMethodload
(self, content: SourceContent, **kwargs: Any)
lib/crewai-tools/src/crewai_tools/rag/base_loader.py:24
↓ 36 callersMethodcall
Call the LLM with the given messages. Args: messages: Input messages for the LLM. Can be a string or list of
lib/crewai/src/crewai/llms/base_llm.py:312
↓ 36 callersMethodrun
Run all checks. Later checks are skipped when earlier ones make them impossible (e.g. no pyproject.toml → no lockfile check).
lib/cli/src/crewai_cli/deploy/validate.py:177
↓ 35 callersMethodload
Load the data from the specified file using pickle. Returns: The data loaded from the file.
lib/crewai/src/crewai/utilities/file_handler.py:154
↓ 34 callersFunction_app_with_plan
()
lib/cli/tests/test_crew_run_tui.py:39
↓ 34 callersMethodexecute
Execute the update mechanism and return result. Args: client: A2A client instance. message: Message to send.
lib/crewai/src/crewai/a2a/updates/base.py:130
↓ 33 callersMethod_emit_call_completed_event
Emit LLM call completed event.
lib/crewai/src/crewai/llms/base_llm.py:608
↓ 33 callersMethodconfirm
(self)
lib/crewai/tests/test_flow_from_definition.py:139
↓ 33 callersMethodcount
Count records in scope (and subscopes). Args: scope_prefix: Optional scope path (None = all). Returns: Numbe
lib/crewai/src/crewai/memory/storage/backend.py:168
↓ 33 callersMethodsearch
(self, query, limit=5, metadata_filter=None, score_threshold=0.6)
lib/crewai/tests/agents/test_agent.py:1911
↓ 32 callersMethodexecute_task
Execute a task with the agent. Args: task: Task to execute. context: Context to execute the task in. tool
lib/crewai/src/crewai/agent/core.py:740
↓ 32 callersMethodkickoff_async
Asynchronous kickoff method to start the crew execution. Args: inputs: Optional input dictionary for task interpolation.
lib/crewai/src/crewai/crew.py:1096
↓ 32 callersMethodparse
Parse {% js 'script.js' %} tag. Args: parser: Jinja2 parser instance. Returns: Output node with rendered scr
lib/crewai/src/crewai/flow/visualization/renderers/interactive.py:58
↓ 31 callersMethod_make_request
( self, method: HttpMethod, endpoint: str, *, json: Any = None,
lib/crewai-core/src/crewai_core/plus_api.py:173
↓ 31 callersMethod_unsubscribe
(self)
lib/cli/src/crewai_cli/crew_run_tui.py:1780
↓ 31 callersMethodhandle_turn
Append a user message, run one conversational turn, and return output. .. warning:: **EXPERIMENTAL.** This is the public entry po
lib/crewai/src/crewai/experimental/conversational_mixin.py:267
↓ 31 callersFunctionload_crew
Load a ``Crew`` from a JSON/JSONC definition file. The definition file describes the crew's agents, tasks, process type, and default inputs.
lib/crewai/src/crewai/project/crew_loader.py:25
↓ 30 callersFunctionbuild_embedder
(spec: BaseEmbeddingsProvider[T])
lib/crewai/src/crewai/rag/embeddings/factory.py:267
↓ 30 callersMethodexecute_sync
Execute the task synchronously.
lib/crewai/src/crewai/task.py:572
↓ 29 callersFunction_codes
(validator: DeployValidator)
lib/cli/tests/deploy/test_validate.py:100
↓ 29 callersMethodregister
Register an extension. Args: extension: The extension to register.
lib/crewai/src/crewai/a2a/extensions/base.py:178
↓ 29 callersMethodtitle
(self)
lib/crewai/src/crewai/experimental/evaluation/base_evaluator.py:28
↓ 28 callersMethoddump
Save current settings to settings.json.
lib/crewai-core/src/crewai_core/settings.py:234
↓ 28 callersMethodremember
Store a single item in memory (synchronous). Routes through the same serialized save pool as ``remember_many`` to prevent races, but
lib/crewai/src/crewai/memory/unified_memory.py:430
↓ 28 callersFunctionvalidate_url
Validate that a URL is safe to fetch. Blocks ``file://`` scheme entirely. For ``http``/``https``, resolves DNS and checks that the target IP
lib/crewai-tools/src/crewai_tools/security/safe_path.py:161
↓ 27 callersFunction_write_crew
(project_dir: Path, crew_def: dict)
lib/crewai/tests/project/test_crew_loader.py:59
↓ 27 callersFunctioninterpolate_only
Interpolate placeholders (e.g., {key}) in a string while leaving JSON untouched. Only interpolates placeholders that follow the pattern {variable_
lib/crewai/src/crewai/utilities/string_utils.py:79
↓ 27 callersFunctionreset_last_event_id
Reset the last event ID to None. Should be called at the start of a new flow or when resetting event state.
lib/crewai/src/crewai/events/event_context.py:83
↓ 27 callersMethodresult
Return the final result after stream exhaustion or completion.
lib/crewai/src/crewai/types/streaming.py:77
↓ 26 callersMethod_safe_telemetry_operation
Execute telemetry operation safely, checking both readiness and environment variables. Args: operation: A callable that performs
lib/crewai/src/crewai/telemetry/telemetry.py:250
↓ 26 callersMethod_subscribe
(self)
lib/cli/src/crewai_cli/crew_run_tui.py:1839
↓ 26 callersFunction_write_agent
(agents_dir: Path, name: str, **overrides)
lib/crewai/tests/project/test_crew_loader.py:47
↓ 26 callersMethodread
Retrieve a cached tool result. Args: tool: Name of the tool. input: Input string used for the tool. Returns:
lib/crewai/src/crewai/agents/cache/cache_handler.py:37
↓ 25 callersFunctionbuild_flow_structure
Build a visualization structure projection from a FlowDefinition.
lib/crewai/src/crewai/flow/visualization/builder.py:169
↓ 25 callersFunctioncreate_llm
Creates or returns an LLM instance based on the given llm_value. Args: llm_value: LLM instance, model name string, config dict, None, or
lib/crewai/src/crewai/utilities/llm_utils.py:13
↓ 25 callersMethodgather
(self)
lib/crewai/tests/test_flow_ask.py:166
↓ 25 callersFunctiongenerate_model_description
Generate JSON schema description of a Pydantic model. This function takes a Pydantic model class and returns its JSON schema, which includes
lib/crewai/src/crewai/utilities/pydantic_schema_utils.py:638
↓ 24 callersFunction_create_analyst_crew
Create a simple analyst crew for file analysis.
lib/crewai/tests/test_crew_multimodal.py:95
↓ 24 callersMethod_track_token_usage_internal
Track token usage from Bedrock response.
lib/crewai/src/crewai/llms/providers/bedrock/completion.py:2067
↓ 24 callersMethodask
Request input from the user during flow execution. Blocks the current thread until the user provides input or the timeout expires. Wo
lib/crewai/src/crewai/flow/runtime/__init__.py:3015
↓ 24 callersFunctionconvert_tools_to_openai_schema
Convert CrewAI tools to OpenAI function calling format. This function converts CrewAI BaseTool and CrewStructuredTool objects into the OpenAI
lib/crewai/src/crewai/utilities/agent_utils.py:154
↓ 24 callersMethodprompt
Generates the task prompt with optional markdown formatting. When the markdown attribute is True, instructions for formatting the res
lib/crewai/src/crewai/task.py:890
↓ 24 callersMethodresult
(self)
lib/crewai/tests/test_flow.py:1578
↓ 23 callersMethod_apply_stop_words
Apply stop words to truncate response content. This method provides consistent stop word behavior across all native SDK providers. Na
lib/crewai/src/crewai/llms/base_llm.py:452
↓ 23 callersFunction_build_multimodal_message
Build a multimodal message with text and file content.
lib/crewai/tests/llms/test_multimodal_integration.py:78
↓ 23 callersFunction_mock_response
Build a ``requests.Response``-like mock with the attributes used by ``_make_request``.
lib/crewai-tools/tests/tools/brave_search_tool_test.py:37
↓ 23 callersMethodremove
Sync wrapper for aremove.
lib/crewai-files/src/crewai_files/cache/upload_cache.py:460
↓ 23 callersFunctionreset_emission_counter
Reset the emission sequence counter to 1. Resets for the current context only.
lib/crewai/src/crewai/events/base_events.py:49
↓ 22 callersMethod_effective_stream
Return the call-scoped streaming mode for this instance.
lib/crewai/src/crewai/llms/base_llm.py:237
↓ 22 callersMethod_generate_description
(self)
lib/crewai-tools/src/crewai_tools/tools/patronus_eval_tool/patronus_eval_tool.py:102
↓ 22 callersMethodcopy
Creates a deep copy of the Task while preserving its original class type. Args: agents: List of agents available for the task.
lib/crewai/src/crewai/task.py:1073
↓ 22 callersFunctionget_before_llm_call_hooks
Get all registered global before_llm_call hooks. Returns: List of registered before hooks
lib/crewai/src/crewai/hooks/llm_hooks.py:221
next →1–100 of 12,753, ranked by callers