brk-code

harness-sdk の API リファレンス

harness-sdk (strands-agents/harness-sdk) の公開 API 369 件 —— クラス 176、関数 48、メソッド 145。実際のソースを静的解析して抽出した正確なシグネチャを掲載しています。

リポジトリ: strands-agents/harness-sdk

種別件数
クラス176
関数48
メソッド145

API 一覧

classstrands-mcp.src.strands_mcp_server.config.Config
Configuration settings for the MCP server.
funcstrands-mcp.src.strands_mcp_server.server.main() -> None
Main entry point for the MCP server.
funcstrands-mcp.src.strands_mcp_server.server.search_docs(query:str, k:int=5) -> List[Dict[str, Any]]
Search the curated documentation catalog.
funcstrands-mcp.src.strands_mcp_server.utils.cache.ensure_page(url:str) -> doc_fetcher.Page | None
Ensure a page is cached, fetching it if necessary.
funcstrands-mcp.src.strands_mcp_server.utils.cache.get_index() -> indexer.IndexSearch | None
Get the current search index instance.
funcstrands-mcp.src.strands_mcp_server.utils.cache.get_url_cache() -> Dict[str, doc_fetcher.Page | None]
Get the URL cache dictionary.
funcstrands-mcp.src.strands_mcp_server.utils.cache.get_url_titles() -> Dict[str, str]
Get the curated URL titles mapping.
classstrands-mcp.src.strands_mcp_server.utils.doc_fetcher.Page
Represents a fetched and cleaned documentation page.
funcstrands-mcp.src.strands_mcp_server.utils.doc_fetcher.fetch_and_clean(page_url:str) -> Page
Fetch a web page and return cleaned content.
funcstrands-mcp.src.strands_mcp_server.utils.doc_fetcher.parse_llms_txt(url:str) -> list[tuple[str, str]]
Parse an llms.txt file and extract document links.
funcstrands-mcp.src.strands_mcp_server.utils.text_processor.extract_preamble(content:str) -> str
Extract the preamble text before the first H2 section.
funcstrands-mcp.src.strands_mcp_server.utils.text_processor.index_title_variants(display_title:str, url:str) -> str
Generate searchable title variants for indexing.
funcstrands-mcp.src.strands_mcp_server.utils.text_processor.make_snippet(page:Page | None, display_title:str, max_chars:int=300) -> str
Create a contextual snippet from page content.
funcstrands-mcp.src.strands_mcp_server.utils.text_processor.normalize(s:str) -> str
Normalize whitespace in a string.
funcstrands-mcp.src.strands_mcp_server.utils.text_processor.normalize_for_comparison(string:str) -> str
Normalize string for case-insensitive comparison.
funcstrands-mcp.src.strands_mcp_server.utils.text_processor.title_from_url(url:str) -> str
Generate a human-readable title from a URL path.
classstrands-py.src.strands._identifier.Identifier
Strands identifier types.
funcstrands-py.src.strands._identifier.new_uuid7() -> str
Return a fresh, monotonic UUID version 7 (RFC 9562).
funcstrands-py.src.strands._identifier.validate(id_:str, type_:Identifier) -> str
Validate strands id.
classstrands-py.src.strands._middleware.stages.AgentStreamContext
Context passed to AgentStreamStage middleware.
methodstrands-py.src.strands._middleware.stages.AgentStreamContext.interrupt(name:str, *reason:Any=None, *response:Any=None) -> MiddlewareInterruptResult
Request a human-in-the-loop interrupt.
classstrands-py.src.strands._middleware.stages.ExecuteToolContext
Context passed to ExecuteToolStage middleware.
methodstrands-py.src.strands._middleware.stages.ExecuteToolContext.interrupt(name:str, *reason:Any=None, *response:Any=None) -> MiddlewareInterruptResult
Request a human-in-the-loop interrupt.
classstrands-py.src.strands._middleware.stages.InvokeModelContext
Context passed to InvokeModelStage middleware.
classstrands-py.src.strands.agent.a2a_agent.A2AAgent
Client wrapper for remote A2A agents.
methodstrands-py.src.strands.agent.a2a_agent.A2AAgent.get_agent_card() -> AgentCard
Fetch and return the remote agent's card.
methodstrands-py.src.strands.agent.a2a_agent.A2AAgent.invoke_async(prompt:AgentInput=None, **kwargs:Any) -> AgentResult
Asynchronously invoke the remote A2A agent.
methodstrands-py.src.strands.agent.a2a_agent.A2AAgent.stream_async(prompt:AgentInput=None, **kwargs:Any) -> AsyncIterator[Any]
Stream remote agent execution asynchronously.
classstrands-py.src.strands.agent.agent.Agent
Core Agent implementation.
methodstrands-py.src.strands.agent.agent.Agent.cancel() -> None
Cancel the currently running agent invocation.
methodstrands-py.src.strands.agent.agent.Agent.cleanup() -> None
Clean up resources used by the agent.
methodstrands-py.src.strands.agent.agent.Agent.load_snapshot(snapshot:Snapshot) -> None
Restore agent state from a previously captured snapshot.
methodstrands-py.src.strands.agent.agent.Agent.tool() -> _ToolCaller
Call tool as a function.
methodstrands-py.src.strands.agent.agent.Agent.tool_names() -> list[str]
Get a list of all registered tool names.
methodstrands-py.src.strands.agent.base.AgentBase.stream_async(prompt:AgentInput=None, **kwargs:Any) -> AsyncIterator[Any]
Stream agent execution asynchronously.
funcstrands-py.src.strands.event_loop.streaming.remove_blank_messages_content_text(messages:Messages) -> Messages
Remove or replace blank text in message content.
funcstrands-py.src.strands.experimental.bidi._async.stop_all(*funcs:Callable[..., Awaitable[None]]) -> None
Call all stops in sequence and aggregate errors.
funcstrands-py.src.strands.experimental.bidi._telemetry.end_connection_span(tracer:Tracer, span:Span, error:Exception | None=None) -> None
End the model connection span.
funcstrands-py.src.strands.experimental.bidi._telemetry.end_response_span(tracer:Tracer, span:Span, stop_reason:str | None=None, time_to_first_audio_ms:int | None=None, error:Exception | None=None) -> None
End a model response span.
funcstrands-py.src.strands.experimental.bidi._telemetry.end_restart_span(tracer:Tracer, span:Span, error:Exception | None=None) -> None
End a connection restart span.
funcstrands-py.src.strands.experimental.bidi._telemetry.start_response_span(tracer:Tracer, response_id:str, parent_span:Span | None=None) -> Span
Start a span for a model response.
funcstrands-py.src.strands.experimental.bidi._telemetry.start_restart_span(tracer:Tracer, parent_span:Span | None=None, error_message:str | None=None) -> Span
Start a span for a connection restart.
methodstrands-py.src.strands.experimental.bidi.agent.agent.BidiAgent.tool() -> _ToolCaller
Call tool as a function.
methodstrands-py.src.strands.experimental.bidi.agent.agent.BidiAgent.tool_names() -> list[str]
Get a list of all registered tool names.
classstrands-py.src.strands.experimental.bidi.io.audio.BidiAudioIO
Send and receive audio data from devices.
methodstrands-py.src.strands.experimental.bidi.io.audio.BidiAudioIO.input() -> _BidiAudioInput
Return audio processing BidiInput.
methodstrands-py.src.strands.experimental.bidi.io.audio.BidiAudioIO.output() -> _BidiAudioOutput
Return audio processing BidiOutput.
classstrands-py.src.strands.experimental.bidi.models.model.BidiModel
Protocol for bidirectional streaming models.
classstrands-py.src.strands.experimental.bidi.models.model.BidiModelTimeoutError
Model timeout error.
classstrands-py.src.strands.experimental.bidi.types.events.BidiAudioStreamEvent
Streaming audio output from the model.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiAudioStreamEvent.audio() -> str
Base64-encoded audio string.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiAudioStreamEvent.format() -> AudioFormat
Audio encoding format.
classstrands-py.src.strands.experimental.bidi.types.events.BidiConnectionCloseEvent
Streaming connection closed.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiConnectionCloseEvent.reason() -> str
Why the interruption occurred.
classstrands-py.src.strands.experimental.bidi.types.events.BidiErrorEvent
Error occurred during the session.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiErrorEvent.error() -> Exception
The original exception that occurred.
classstrands-py.src.strands.experimental.bidi.types.events.BidiInterruptionEvent
Model generation was interrupted.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiInterruptionEvent.reason() -> str
Why the interruption occurred.
classstrands-py.src.strands.experimental.bidi.types.events.BidiResponseCompleteEvent
Model finished generating response.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiResponseCompleteEvent.response_id() -> str
Unique identifier for this response.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiResponseCompleteEvent.stop_reason() -> StopReason
Why the response ended.
classstrands-py.src.strands.experimental.bidi.types.events.BidiResponseStartEvent
Model starts generating a response.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiResponseStartEvent.response_id() -> str
Unique identifier for this response.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiTextInputEvent.role() -> Role
The role of the message sender.
methodstrands-py.src.strands.experimental.bidi.types.events.BidiTextInputEvent.text() -> str
The text content to send to the model.
classstrands-py.src.strands.experimental.bidi.types.events.ModalityUsage
Token usage for a specific modality.
classstrands-py.src.strands.experimental.bidi.types.io.BidiInput
Protocol for bidirectional input callables.
methodstrands-py.src.strands.experimental.bidi.types.io.BidiInput.start(agent:'BidiAgent') -> None
Start input.
methodstrands-py.src.strands.experimental.bidi.types.io.BidiInput.stop() -> None
Stop input.
classstrands-py.src.strands.experimental.bidi.types.io.BidiOutput
Protocol for bidirectional output callables.
methodstrands-py.src.strands.experimental.bidi.types.io.BidiOutput.start(agent:'BidiAgent') -> None
Start output.
methodstrands-py.src.strands.experimental.bidi.types.io.BidiOutput.stop() -> None
Stop output.
classstrands-py.src.strands.experimental.checkpoint.checkpoint.Checkpoint
Pause-point marker.
methodstrands-py.src.strands.experimental.checkpoint.checkpoint.Checkpoint.from_dict(data:dict[str, Any]) -> 'Checkpoint'
Reconstruct from a dict produced by to_dict().
methodstrands-py.src.strands.experimental.checkpoint.checkpoint.Checkpoint.to_dict() -> dict[str, Any]
Serialize for persistence.
classstrands-py.src.strands.experimental.hooks.events.BidiHookEvent
Base class for BidiAgent hook events.
funcstrands-py.src.strands.handlers.callback_handler.null_callback_handler(**_kwargs:Any) -> None
Callback handler that discards all output.
classstrands-py.src.strands.hooks.events.AfterInvocationEvent
Event triggered at the end of an agent request.
classstrands-py.src.strands.hooks.events.AfterToolCallEvent
Event triggered after a tool invocation completes.
classstrands-py.src.strands.hooks.events.AfterToolsEvent
Event triggered after all tools complete execution.
classstrands-py.src.strands.hooks.events.BeforeModelCallEvent
Event triggered before the model is invoked.
classstrands-py.src.strands.hooks.events.BeforeToolCallEvent
Event triggered before a tool is invoked.
classstrands-py.src.strands.hooks.events.BeforeToolsEvent
Event triggered before executing tools.
classstrands-py.src.strands.hooks.registry.BaseHookEvent
Base class for all hook events.
classstrands-py.src.strands.hooks.registry.HookEvent
Base class for single agent hook events.
classstrands-py.src.strands.hooks.registry.HookOrder
Named constants for hook execution priority.
methodstrands-py.src.strands.hooks.registry.HookRegistry.add_hook(hook:HookProvider) -> None
Register all callbacks from a hook provider.
methodstrands-py.src.strands.interrupt.Interrupt.to_dict() -> dict[str, Any]
Serialize to dict for session management.
classstrands-py.src.strands.interrupt.InterruptException
Exception raised when human input is required.
classstrands-py.src.strands.interventions.actions.Confirm
Request human approval before proceeding.
classstrands-py.src.strands.interventions.actions.Deny
Block the operation.
classstrands-py.src.strands.interventions.actions.Guide
Provide feedback to steer behavior.
classstrands-py.src.strands.interventions.actions.Proceed
Allow the operation to continue unchanged.
classstrands-py.src.strands.interventions.actions.Transform
Modify event content in-place.
funcstrands-py.src.strands.interventions.actions.default_evaluate(response:Any) -> bool
Default evaluate function for the confirm action.
classstrands-py.src.strands.interventions.handler.InterventionHandler
Base class for intervention handlers.
methodstrands-py.src.strands.interventions.handler.InterventionHandler.name() -> str
Unique name identifying this handler.
methodstrands-py.src.strands.interventions.handler.InterventionHandler.on_error() -> OnError
What to do when this handler throws.
classstrands-py.src.strands.memory.extraction.triggers.InvocationTrigger
Runs extraction after every agent invocation.
classstrands-py.src.strands.memory.extraction.types.ExtractionConfig
Per-store automatic-extraction configuration.
classstrands-py.src.strands.memory.extraction.types.ExtractorContext
Context passed to :meth:`Extractor.extract`.
funcstrands-py.src.strands.memory.memory_manager.MemoryManager.add_memory(entries:list[str], stores:list[str] | None=None) -> dict[str, int]
Add data to long-term memory.
funcstrands-py.src.strands.memory.memory_manager.MemoryManager.search_memory(query:str, max_search_results:int | None=None, stores:list[str] | None=None) -> list[dict[str, Any]]
Search long-term memory.
classstrands-py.src.strands.memory.types.MemoryAddOptions
Options for ``MemoryManager.add``.
classstrands-py.src.strands.memory.types.MemoryAddToolConfig
Configuration for the ``add_memory`` tool.
classstrands-py.src.strands.memory.types.MemoryInjectionConfig
Configuration for memory context injection.
classstrands-py.src.strands.memory.types.MemorySearchOptions
Options for ``MemoryManager.search``.
classstrands-py.src.strands.memory.types.MemoryStore
Runtime contract for a memory store backend.
methodstrands-py.src.strands.memory.types.MemoryStore.add(content:str, metadata:Metadata | None=None) -> Any
Add a single piece of content to the store.
classstrands-py.src.strands.memory.types.SearchOptions
Options passed to :meth:`MemoryStore.search`.
funcstrands-py.src.strands.models._defaults.get_context_window_limit(model_id:str) -> int | None
Look up the context window limit for a model ID.
funcstrands-py.src.strands.models._validation.validate_config_keys(config_dict:Mapping[str, Any], config_class:type) -> None
Validate that config keys match the TypedDict fields.
classstrands-py.src.strands.models.anthropic.AnthropicModel
Anthropic model provider implementation.
classstrands-py.src.strands.models.anthropic.AnthropicModel.AnthropicConfig
Configuration options for Anthropic models.
methodstrands-py.src.strands.models.anthropic.AnthropicModel.get_config() -> AnthropicConfig
Get the Anthropic model configuration.
classstrands-py.src.strands.models.bedrock.BedrockModel
AWS Bedrock model provider implementation.
classstrands-py.src.strands.models.bedrock.BedrockModel.BedrockConfig
Configuration options for Bedrock models.
methodstrands-py.src.strands.models.bedrock.BedrockModel.get_config() -> BedrockConfig
Get the current Bedrock Model configuration.
classstrands-py.src.strands.models.gemini.GeminiModel
Google Gemini model provider implementation.
classstrands-py.src.strands.models.gemini.GeminiModel.GeminiConfig
Configuration options for Gemini models.
methodstrands-py.src.strands.models.gemini.GeminiModel.get_config() -> GeminiConfig
Get the Gemini model configuration.
classstrands-py.src.strands.models.litellm.LiteLLMModel
LiteLLM model provider implementation.
classstrands-py.src.strands.models.litellm.LiteLLMModel.LiteLLMConfig
Configuration options for LiteLLM models.
methodstrands-py.src.strands.models.litellm.LiteLLMModel.format_request_message_content(content:ContentBlock, **kwargs:Any) -> dict[str, Any]
Format a LiteLLM content block.
methodstrands-py.src.strands.models.litellm.LiteLLMModel.get_config() -> LiteLLMConfig
Get the LiteLLM model configuration.
classstrands-py.src.strands.models.llamaapi.LlamaAPIModel
Llama API model provider implementation.
classstrands-py.src.strands.models.llamaapi.LlamaAPIModel.LlamaConfig
Configuration options for Llama API models.
methodstrands-py.src.strands.models.llamaapi.LlamaAPIModel.get_config() -> LlamaConfig
Get the Llama API model configuration.
classstrands-py.src.strands.models.llamacpp.LlamaCppModel
llama.cpp model provider implementation.
classstrands-py.src.strands.models.llamacpp.LlamaCppModel.LlamaCppConfig
Configuration options for llama.cpp models.
methodstrands-py.src.strands.models.llamacpp.LlamaCppModel.get_config() -> LlamaCppConfig
Get the llama.cpp model configuration.
classstrands-py.src.strands.models.mistral.MistralModel
Mistral API model provider implementation.
classstrands-py.src.strands.models.mistral.MistralModel.MistralConfig
Configuration parameters for Mistral models.
methodstrands-py.src.strands.models.mistral.MistralModel.get_config() -> MistralConfig
Get the Mistral model configuration.
classstrands-py.src.strands.models.model.BaseModelConfig
Base configuration shared by all model providers.
classstrands-py.src.strands.models.model.CacheConfig
Configuration for prompt caching.
classstrands-py.src.strands.models.model.CacheToolsConfig
Configuration for the toolConfig cache point.
classstrands-py.src.strands.models.model.Model
Abstract base class for Agent model providers.
methodstrands-py.src.strands.models.model.Model.get_config() -> Any
Return the model configuration.
classstrands-py.src.strands.models.ollama.OllamaModel
Ollama model provider implementation.
classstrands-py.src.strands.models.ollama.OllamaModel.OllamaConfig
Configuration parameters for Ollama models.
methodstrands-py.src.strands.models.ollama.OllamaModel.get_config() -> OllamaConfig
Get the Ollama model configuration.
methodstrands-py.src.strands.models.openai.Client.chat() -> Any
Chat completions interface.
classstrands-py.src.strands.models.openai.OpenAIModel
OpenAI model provider implementation.
classstrands-py.src.strands.models.openai.OpenAIModel.OpenAIConfig
Configuration options for OpenAI models.
methodstrands-py.src.strands.models.openai.OpenAIModel.format_request_message_content(content:ContentBlock, **kwargs:Any) -> dict[str, Any]
Format an OpenAI compatible content block.
methodstrands-py.src.strands.models.openai.OpenAIModel.format_request_message_tool_call(tool_use:ToolUse, **kwargs:Any) -> dict[str, Any]
Format an OpenAI compatible tool call.
methodstrands-py.src.strands.models.openai.OpenAIModel.format_request_tool_message(tool_result:ToolResult, **kwargs:Any) -> dict[str, Any]
Format an OpenAI compatible tool message.
methodstrands-py.src.strands.models.openai.OpenAIModel.get_config() -> OpenAIConfig
Get the OpenAI model configuration.
methodstrands-py.src.strands.models.openai_responses.Client.responses() -> Any
Responses interface.
classstrands-py.src.strands.models.sagemaker.FunctionCall
Function call for the model.
classstrands-py.src.strands.models.sagemaker.SageMakerAIModel
Amazon SageMaker model provider implementation.
methodstrands-py.src.strands.models.sagemaker.SageMakerAIModel.format_request_message_content(content:ContentBlock, **kwargs:Any) -> dict[str, Any]
Format a content block.
classstrands-py.src.strands.models.sagemaker.ToolCall
Tool call for the model object.
classstrands-py.src.strands.models.sagemaker.UsageMetadata
Usage metadata for the model.
classstrands-py.src.strands.models.writer.WriterModel
Writer API model provider implementation.
classstrands-py.src.strands.models.writer.WriterModel.WriterConfig
Configuration options for Writer API.
methodstrands-py.src.strands.models.writer.WriterModel.get_config() -> WriterConfig
Get the Writer model configuration.
funcstrands-py.src.strands.multiagent.a2a._converters.convert_content_blocks_to_parts(content_blocks:list[ContentBlock]) -> list[Part]
Convert Strands ContentBlocks to A2A Parts.
funcstrands-py.src.strands.multiagent.a2a._converters.convert_input_to_message(prompt:AgentInput) -> A2AMessage
Convert AgentInput to A2A Message.
funcstrands-py.src.strands.multiagent.a2a._converters.convert_response_to_agent_result(response:A2AResponse) -> AgentResult
Convert A2A response to AgentResult.
classstrands-py.src.strands.multiagent.a2a.server.A2AServer
A2A-compatible wrapper for Strands Agent.
methodstrands-py.src.strands.multiagent.a2a.server.A2AServer.agent_card_url() -> str
Get the URL advertised in the AgentCard.
methodstrands-py.src.strands.multiagent.a2a.server.A2AServer.public_agent_card() -> AgentCard
Get the public AgentCard for this agent.
classstrands-py.src.strands.multiagent.base.MultiAgentBase
Base class for multi-agent helpers.
methodstrands-py.src.strands.multiagent.base.MultiAgentBase.deserialize_state(payload:dict[str, Any]) -> None
Restore orchestrator state from a session dict.
methodstrands-py.src.strands.multiagent.base.MultiAgentBase.invoke_async(task:MultiAgentInput, invocation_state:dict[str, Any] | None=None, **kwargs:Any) -> MultiAgentResult
Invoke asynchronously.
classstrands-py.src.strands.multiagent.base.Status
Execution status for both graphs and nodes.
methodstrands-py.src.strands.multiagent.graph.Graph.add_hook(callback:HookCallback, event_type:type | list[type] | None=None, *order:float=HookOrder.DEFAULT) -> None
Register a hook callback with the graph.
methodstrands-py.src.strands.multiagent.graph.Graph.invoke_async(task:MultiAgentInput, invocation_state:dict[str, Any] | None=None, **kwargs:Any) -> GraphResult
Invoke the graph asynchronously.
methodstrands-py.src.strands.multiagent.graph.Graph.stream_async(task:MultiAgentInput, invocation_state:dict[str, Any] | None=None, **kwargs:Any) -> AsyncIterator[dict[str, Any]]
Stream events during graph execution.
classstrands-py.src.strands.multiagent.graph.GraphBuilder
Builder pattern for constructing graphs.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_entry_point(node_id:str) -> 'GraphBuilder'
Set a node as an entry point for graph execution.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_execution_timeout(timeout:float) -> 'GraphBuilder'
Set total execution timeout.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_graph_id(graph_id:str) -> 'GraphBuilder'
Set graph id.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_hook_providers(hooks:list[HookProvider]) -> 'GraphBuilder'
Set hook providers for the graph.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_max_node_executions(max_executions:int) -> 'GraphBuilder'
Set maximum number of node executions allowed.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_node_timeout(timeout:float) -> 'GraphBuilder'
Set individual node execution timeout.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_plugins(plugins:list[MultiAgentPlugin]) -> 'GraphBuilder'
Set plugins for the graph.
methodstrands-py.src.strands.multiagent.graph.GraphBuilder.set_session_manager(session_manager:SessionManager) -> 'GraphBuilder'
Set session manager for the graph.
classstrands-py.src.strands.multiagent.graph.GraphNode
Represents a node in the graph.
classstrands-py.src.strands.multiagent.graph.GraphState
Graph execution state.
classstrands-py.src.strands.multiagent.swarm.SharedContext
Shared context between swarm nodes.
methodstrands-py.src.strands.multiagent.swarm.SharedContext.add_context(node:SwarmNode, key:str, value:Any) -> None
Add context.
methodstrands-py.src.strands.multiagent.swarm.Swarm.add_hook(callback:HookCallback, event_type:type | list[type] | None=None, *order:float=HookOrder.DEFAULT) -> None
Register a hook callback with the swarm.
methodstrands-py.src.strands.multiagent.swarm.Swarm.invoke_async(task:MultiAgentInput, invocation_state:dict[str, Any] | None=None, **kwargs:Any) -> SwarmResult
Invoke the swarm asynchronously.
methodstrands-py.src.strands.multiagent.swarm.Swarm.stream_async(task:MultiAgentInput, invocation_state:dict[str, Any] | None=None, **kwargs:Any) -> AsyncIterator[dict[str, Any]]
Stream events during swarm execution.
classstrands-py.src.strands.multiagent.swarm.SwarmNode
Represents a node (e.g.
classstrands-py.src.strands.multiagent.swarm.SwarmState
Current state of swarm execution.
methodstrands-py.src.strands.plugins.plugin.Plugin.init_agent(agent:'Agent') -> None | Awaitable[None]
Initialize the agent instance.
methodstrands-py.src.strands.plugins.plugin.Plugin.name() -> str
A stable string identifier for the plugin.
classstrands-py.src.strands.sandbox.base.Sandbox
Abstract execution environment.
methodstrands-py.src.strands.sandbox.base.Sandbox.get_tools() -> list[AgentTool]
Tools this sandbox vends to an agent.
methodstrands-py.src.strands.sandbox.base.Sandbox.list_files(path:str, **kwargs:Any) -> list[FileInfo]
List files in a sandbox directory.
methodstrands-py.src.strands.sandbox.base.Sandbox.read_file(path:str, **kwargs:Any) -> bytes
Read a file from the sandbox filesystem as raw bytes.
methodstrands-py.src.strands.sandbox.base.Sandbox.read_text(path:str, encoding:str='utf-8', **kwargs:Any) -> str
Read a text file from the sandbox filesystem.
methodstrands-py.src.strands.sandbox.base.Sandbox.remove_file(path:str, **kwargs:Any) -> None
Remove a file from the sandbox filesystem.
methodstrands-py.src.strands.sandbox.base.Sandbox.write_file(path:str, content:bytes, **kwargs:Any) -> None
Write raw bytes to a file in the sandbox filesystem.
methodstrands-py.src.strands.sandbox.base.Sandbox.write_text(path:str, content:str, encoding:str='utf-8', **kwargs:Any) -> None
Write a text file to the sandbox filesystem.
classstrands-py.src.strands.sandbox.ssh.SshSandbox
Execute commands on a remote host via SSH.
classstrands-py.src.strands.sandbox.types.ExecutionResult
Result of command or code execution in a sandbox.
classstrands-py.src.strands.sandbox.types.FileInfo
Metadata about a file or directory in a sandbox.
classstrands-py.src.strands.sandbox.types.OutputFile
A file produced as output by code execution.
classstrands-py.src.strands.session.s3_session_manager.S3SessionManager
S3-based session manager for cloud storage.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.create_agent(session_id:str, session_agent:SessionAgent, **kwargs:Any) -> None
Create a new agent in S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.create_message(session_id:str, agent_id:str, session_message:SessionMessage, **kwargs:Any) -> None
Create a new message in S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.create_multi_agent(session_id:str, multi_agent:'MultiAgentBase', **kwargs:Any) -> None
Create a new multiagent state in S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.create_session(session:Session, **kwargs:Any) -> Session
Create a new session in S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.delete_session(session_id:str, **kwargs:Any) -> None
Delete session and all associated data from S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.read_agent(session_id:str, agent_id:str, **kwargs:Any) -> SessionAgent | None
Read agent data from S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.read_message(session_id:str, agent_id:str, message_id:int, **kwargs:Any) -> SessionMessage | None
Read message data from S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.read_multi_agent(session_id:str, multi_agent_id:str, **kwargs:Any) -> dict[str, Any] | None
Read multi-agent state from S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.read_session(session_id:str, **kwargs:Any) -> Session | None
Read session data from S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.update_agent(session_id:str, session_agent:SessionAgent, **kwargs:Any) -> None
Update agent data in S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.update_message(session_id:str, agent_id:str, session_message:SessionMessage, **kwargs:Any) -> None
Update message data in S3.
methodstrands-py.src.strands.session.s3_session_manager.S3SessionManager.update_multi_agent(session_id:str, multi_agent:'MultiAgentBase', **kwargs:Any) -> None
Update multi-agent state in S3.
classstrands-py.src.strands.session.session_manager.SessionManager
Abstract interface for managing sessions.
methodstrands-py.src.strands.session.session_manager.SessionManager.append_message(message:Message, agent:'Agent', **kwargs:Any) -> None
Append a message to the agent's session.
methodstrands-py.src.strands.session.session_manager.SessionManager.initialize(agent:'Agent', **kwargs:Any) -> None
Initialize an agent with a session.
methodstrands-py.src.strands.storage.in_memory_storage.InMemoryStorage.clear() -> None
Remove all stored entries.
methodstrands-py.src.strands.storage.in_memory_storage.InMemoryStorage.delete(key:str) -> None
Delete the value stored under key.
methodstrands-py.src.strands.storage.in_memory_storage.InMemoryStorage.list(query:str='') -> builtins.list[str]
List keys matching the given prefix.
methodstrands-py.src.strands.storage.in_memory_storage.InMemoryStorage.read(key:str) -> bytes | None
Retrieve the bytes previously stored under key.
methodstrands-py.src.strands.storage.in_memory_storage.InMemoryStorage.write(key:str, data:bytes) -> None
Store data under key, overwriting any existing value.
methodstrands-py.src.strands.storage.local_file_storage.LocalFileStorage.delete(key:str) -> None
Delete the file corresponding to key.
methodstrands-py.src.strands.storage.local_file_storage.LocalFileStorage.for_sandbox(sandbox:Sandbox) -> LocalFileStorage
Return a copy bound to the given sandbox.
methodstrands-py.src.strands.storage.local_file_storage.LocalFileStorage.read(key:str) -> bytes | None
Read the file corresponding to key.
classstrands-py.src.strands.storage.s3_storage.S3Storage
Persists bytes as objects in an Amazon S3 bucket.
methodstrands-py.src.strands.storage.s3_storage.S3Storage.delete(key:str) -> None
Delete an S3 object.
methodstrands-py.src.strands.storage.s3_storage.S3Storage.list(query:str='') -> builtins.list[str]
List S3 objects matching the given prefix.
methodstrands-py.src.strands.storage.s3_storage.S3Storage.namespace(prefix:str) -> _NamespacedStorage
Return a view of this storage with all keys prefixed.
methodstrands-py.src.strands.storage.s3_storage.S3Storage.read(key:str) -> bytes | None
Read an S3 object.
methodstrands-py.src.strands.storage.s3_storage.S3Storage.write(key:str, data:bytes) -> None
Store data as an S3 object.
methodstrands-py.src.strands.storage.storage.Storage.delete(key:str) -> None
Delete the value stored under key.
methodstrands-py.src.strands.storage.storage.Storage.list(query:ListQuery) -> builtins.list[str]
List keys matching the given prefix query.
methodstrands-py.src.strands.storage.storage.Storage.read(key:str) -> bytes | None
Retrieve the bytes previously stored under key.
methodstrands-py.src.strands.storage.storage.Storage.write(key:str, data:bytes) -> None
Store data under key, overwriting any existing value.
classstrands-py.src.strands.telemetry.metrics.AgentInvocation
Metrics for a single agent invocation.
classstrands-py.src.strands.telemetry.metrics.EventLoopCycleMetric
Aggregated metrics for a single event loop cycle.
classstrands-py.src.strands.telemetry.metrics.EventLoopMetrics
Aggregated metrics for an event loop's execution.
classstrands-py.src.strands.telemetry.metrics.ToolMetrics
Metrics for a specific tool's usage.
methodstrands-py.src.strands.telemetry.metrics.Trace.add_child(child:'Trace') -> None
Add a child trace to this trace.
methodstrands-py.src.strands.telemetry.metrics.Trace.add_message(message:Message) -> None
Add a message to the trace.
methodstrands-py.src.strands.telemetry.metrics.Trace.duration() -> float | None
Calculate the duration of this trace.
classstrands-py.src.strands.telemetry.tracer.Tracer
Handles OpenTelemetry tracing.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_agent_span(span:Span, response:AgentResult | None=None, error:Exception | None=None) -> None
End an agent span with results and metrics.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_memory_add_span(span:Span, store_failure_count:int=0, error:Exception | None=None) -> None
End a memory add span.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_memory_extract_span(span:Span, entry_count:int | None=None, error:Exception | None=None) -> None
End a memory extraction span.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_memory_inject_span(span:Span, injected:bool, entry_count:int=0, format_error:bool=False) -> None
End a memory injection span.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_span_with_error(span:Span, error_message:str, exception:Exception | None=None) -> None
End a span with error status.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_swarm_span(span:Span, result:str | None=None) -> None
End a swarm span with results.
methodstrands-py.src.strands.telemetry.tracer.Tracer.end_tool_call_span(span:Span, tool_result:ToolResult | None, error:Exception | None=None) -> None
End a tool call span with results.
funcstrands-py.src.strands.telemetry.tracer.get_tracer() -> Tracer
Get or create the global tracer.
funcstrands-py.src.strands.telemetry.tracer.serialize(obj:Any) -> str
Serialize an object to JSON with consistent settings.
classstrands-py.src.strands.types._events.CitationStreamEvent
Event emitted during citation streaming.
classstrands-py.src.strands.types._events.ModelStopReason
Event emitted during reasoning signature streaming.
classstrands-py.src.strands.types._events.ModelStreamEvent
Event emitted during model response streaming.
classstrands-py.src.strands.types._events.MultiAgentNodeInterruptEvent
Event emitted when a node is interrupted.
methodstrands-py.src.strands.types._events.MultiAgentNodeInterruptEvent.interrupts() -> list[Interrupt]
The interrupt instances.
classstrands-py.src.strands.types._events.MultiAgentNodeStopEvent
Event emitted when a node stops execution.
classstrands-py.src.strands.types._events.ReasoningTextStreamEvent
Event emitted during reasoning text streaming.
classstrands-py.src.strands.types._events.StartEvent
Event emitted at the start of each event loop cycle.
classstrands-py.src.strands.types._events.TextStreamEvent
Event emitted during text content streaming.
classstrands-py.src.strands.types._events.ToolInterruptEvent
Event emitted when a tool is interrupted.
methodstrands-py.src.strands.types._events.ToolInterruptEvent.interrupts() -> list[Interrupt]
The interrupt instances.
methodstrands-py.src.strands.types._events.ToolInterruptEvent.tool_use_id() -> str
The id of the tool interrupted.
classstrands-py.src.strands.types._events.ToolResultEvent
Event emitted when a tool execution completes.
methodstrands-py.src.strands.types._events.ToolResultEvent.exception() -> Exception | None
The original exception that occurred, if any.
methodstrands-py.src.strands.types._events.ToolResultEvent.tool_use_id() -> str
The toolUseId associated with this result.
classstrands-py.src.strands.types._events.ToolUseStreamEvent
Event emitted during tool use input streaming.
classstrands-py.src.strands.types._events.TypedEvent
Base class for all typed events in the agent system.
methodstrands-py.src.strands.types._snapshot.Snapshot.from_dict(d:dict[str, Any]) -> Snapshot
Reconstruct a Snapshot from a dict produced by to_dict().
methodstrands-py.src.strands.types._snapshot.Snapshot.to_dict() -> dict[str, Any]
Serialize to a plain JSON-compatible dict.
classstrands-py.src.strands.types.agent.ConcurrentInvocationMode
Mode controlling concurrent invocation behavior.
classstrands-py.src.strands.types.agent.Limits
Per-invocation budget caps for the agent loop.
classstrands-py.src.strands.types.citations.CitationsConfig
Configuration for enabling citations on documents.
classstrands-py.src.strands.types.content.ContentBlockDelta
The content block delta event.
classstrands-py.src.strands.types.content.ContentBlockStart
Content block start information.
classstrands-py.src.strands.types.content.ContentBlockStartToolUse
The start of a tool use block.
classstrands-py.src.strands.types.content.ContentBlockStop
A content block stop event.
classstrands-py.src.strands.types.content.DeltaContent
A block of content in a streaming response.
classstrands-py.src.strands.types.content.GuardContent
Content block to be evaluated by guardrails.
classstrands-py.src.strands.types.content.GuardContentText
Text content to be evaluated by guardrails.
classstrands-py.src.strands.types.content.Message
A message in a conversation with the agent.
classstrands-py.src.strands.types.content.MessageMetadata
Optional metadata attached to a message.
classstrands-py.src.strands.types.event_loop.Metrics
Performance metrics for model interactions.
classstrands-py.src.strands.types.event_loop.Usage
Token usage information for model interactions.
classstrands-py.src.strands.types.exceptions.EventLoopException
Exception raised by the event loop.
classstrands-py.src.strands.types.exceptions.ModelThrottledException
Exception raised when the model is throttled.
classstrands-py.src.strands.types.exceptions.SessionException
Exception raised when session operations fail.
classstrands-py.src.strands.types.exceptions.StorageError
Raised when a storage operation fails.
classstrands-py.src.strands.types.guardrails.ContentFilter
The content filter for a guardrail.
classstrands-py.src.strands.types.guardrails.ContentPolicy
An assessment of a content policy for a guardrail.
classstrands-py.src.strands.types.guardrails.CustomWord
Definition of a custom word to be filtered.
classstrands-py.src.strands.types.guardrails.GuardrailConfig
Configuration for content filtering guardrails.
classstrands-py.src.strands.types.guardrails.GuardrailTrace
Trace information from guardrail processing.
classstrands-py.src.strands.types.guardrails.ManagedWord
Definition of a managed word to be filtered.
classstrands-py.src.strands.types.guardrails.Topic
Information about a topic guardrail.
classstrands-py.src.strands.types.guardrails.TopicPolicy
A behavior assessment of a topic policy.
classstrands-py.src.strands.types.guardrails.Trace
A Top level guardrail trace object.
classstrands-py.src.strands.types.guardrails.WordPolicy
The word policy assessment.
classstrands-py.src.strands.types.interrupt.InterruptResponse
User response to an interrupt.
classstrands-py.src.strands.types.media.DocumentContent
A document to include in a message.
classstrands-py.src.strands.types.media.DocumentSource
Contains the content of a document.
classstrands-py.src.strands.types.media.ImageContent
An image to include in a message.
classstrands-py.src.strands.types.media.ImageSource
Contains the content of an image.
classstrands-py.src.strands.types.media.Location
A location for a document.
classstrands-py.src.strands.types.media.S3Location
A storage location in an Amazon S3 bucket.
classstrands-py.src.strands.types.media.VideoContent
A video to include in a message.
classstrands-py.src.strands.types.media.VideoSource
Contains the content of a video.
classstrands-py.src.strands.types.session.Session
Session data model.
classstrands-py.src.strands.types.session.SessionAgent
Agent that belongs to a Session.
methodstrands-py.src.strands.types.session.SessionAgent.from_agent(agent:'Agent') -> 'SessionAgent'
Convert an Agent to a SessionAgent.
methodstrands-py.src.strands.types.session.SessionAgent.from_bidi_agent(agent:'BidiAgent') -> 'SessionAgent'
Convert a BidiAgent to a SessionAgent.
methodstrands-py.src.strands.types.session.SessionAgent.initialize_bidi_internal_state(agent:'BidiAgent') -> None
Initialize internal state of BidiAgent.
methodstrands-py.src.strands.types.session.SessionAgent.initialize_internal_state(agent:'Agent') -> None
Initialize internal state of agent.
classstrands-py.src.strands.types.session.SessionMessage
Message within a SessionAgent.
classstrands-py.src.strands.types.session.SessionType
Enumeration of session types.
funcstrands-py.src.strands.types.session.encode_bytes_values(obj:Any) -> Any
Recursively encode any bytes values in an object to base64.
classstrands-py.src.strands.types.streaming.ContentBlockDelta
A block of content in a streaming response.
classstrands-py.src.strands.types.streaming.ContentBlockDeltaText
Text content delta in a streaming response.
classstrands-py.src.strands.types.streaming.ContentBlockDeltaToolUse
Tool use input delta in a streaming response.
classstrands-py.src.strands.types.streaming.ExceptionEvent
Base event for exceptions in a streaming response.
classstrands-py.src.strands.types.streaming.ModelStreamErrorEvent
Event for model streaming errors.
classstrands-py.src.strands.types.streaming.RedactContentEvent
Event for redacting content.
classstrands-py.src.strands.types.streaming.StreamEvent
The messages output stream.
classstrands-py.src.strands.types.tools.AgentTool
Abstract base class for all SDK tools.
methodstrands-py.src.strands.types.tools.AgentTool.mark_dynamic() -> None
Mark this tool as dynamically loaded.
classstrands-py.src.strands.types.tools.Tool
A tool that can be provided to a model.
classstrands-py.src.strands.types.tools.ToolChoiceAuto
Configuration for automatic tool selection.
classstrands-py.src.strands.types.tools.ToolConfig
Configuration for tools in a model request.
classstrands-py.src.strands.types.tools.ToolResult
Result of a tool execution.
classstrands-py.src.strands.types.tools.ToolResultContent
Content returned by a tool execution.
classstrands-py.src.strands.types.tools.ToolSpec
Specification for a tool that can be used by an agent.
methodstrands-py.src.strands.vended_interventions.cedar.cedar_authorization.CedarAuthorization.reset_call_counts(agent:Agent | None=None) -> None
Clear all rate-limit call counters.
classstrands-py.src.strands.vended_interventions.hitl.classifier.ClassifierResult
Result from a classifier evaluation.
methodstrands-py.src.strands.vended_plugins.context_offloader.storage.FileStorage.retrieve(reference:str) -> tuple[bytes, str]
Retrieve content from a stored file.
classstrands-py.src.strands.vended_plugins.context_offloader.storage.InMemoryStorage
Store offloaded content in memory.
methodstrands-py.src.strands.vended_plugins.context_offloader.storage.InMemoryStorage.clear() -> None
Remove all stored content.
methodstrands-py.src.strands.vended_plugins.context_offloader.storage.InMemoryStorage.retrieve(reference:str) -> tuple[bytes, str]
Retrieve content from memory.
classstrands-py.src.strands.vended_plugins.context_offloader.storage.S3Storage
Store offloaded content in Amazon S3.
methodstrands-py.src.strands.vended_plugins.context_offloader.storage.S3Storage.retrieve(reference:str) -> tuple[bytes, str]
Retrieve content from an S3 object.
methodstrands-py.src.strands.vended_plugins.context_offloader.storage.Storage.retrieve(reference:str) -> tuple[bytes, str]
Retrieve stored content by reference.
funcstrands-py.src.strands.vended_plugins.goal.judge.build_judge_prompt(description:str, transcript:Messages) -> str
Build the judge's input prompt.
classstrands-py.src.strands.vended_plugins.goal.plugin.GoalAttempt
Single attempt summary preserved on GoalResult.
classstrands-py.src.strands.vended_plugins.goal.plugin.GoalLoop
Iterative-refinement plugin.
methodstrands-py.src.strands.vended_plugins.goal.plugin.GoalLoop.init_agent(agent:Agent) -> None
Register hooks on the agent.
methodstrands-py.src.strands.vended_plugins.goal.plugin.GoalLoop.name() -> str
Plugin name.
classstrands-py.src.strands.vended_plugins.goal.plugin.ValidationOutcome
Outcome a validator returns.
classstrands-py.src.strands.vended_plugins.goal.plugin.Validator
Programmatic validator callable.
methodstrands-py.src.strands.vended_plugins.skills.skill.Skill.from_content(content:str, *strict:bool=False) -> Skill
Parse SKILL.md content into a Skill instance.
classstrands-py.src.strands.vended_plugins.steering.core.context.SteeringContext
Container for steering context data.
classstrands-py.src.strands.vended_tools.http_request.http_request.HttpRequestError
Raised when a request fails.
classstrands-py.src.strands.vended_tools.http_request.types.HttpRequestOutput
Output of an HTTP request.
funcstrands-py.src.strands.vended_tools.make_bash(**kwargs:Any) -> 'DecoratedFunctionTool'
Deprecated alias for :func:`make_shell`.
classstrands-py.src.strands.vended_tools.shell.types.ShellOutput
Output of a shell command execution.
funcstrands-py.src.strands.vended_tools.sleep.sleep.sleep_tool(duration:float) -> str
Pauses execution for the given number of seconds.
funcstrands-py.tests_integ._aws.resolve_region(region:str | None=None) -> str
Resolve the AWS region to use for test infrastructure.
funcstrands-py.tests_integ._ssm.read_ssm_parameter(name:str, *with_decryption:bool=False, *region:str | None=None) -> str | None
Read a single SSM parameter by name.
methodstrands-py.tests_integ.bidi.generators.audio.AudioGenerator.clear_cache() -> None
Clear all cached audio files.
funcstrands-py.tests_integ.bidi.generators.audio.generate_test_audio(text:str, use_cache:bool=True) -> dict
Generate test audio input event from text.
classstrands-py.tests_integ.mcp.echo_server.EchoResponse
Response model for echo with structured content.
funcstrands-py.tests_integ.mcp.echo_server.static_binary_resource() -> bytes
A static binary resource (image) for testing
funcstrands-py.tests_integ.mcp.echo_server.static_text_resource() -> str
A static text resource for testing
funcstrands-py.tests_integ.mcp.echo_server.template_resource(id:str) -> str
A resource template with parameter substitution
funcstrands-py.tests_integ.mcp.elicitation_server.approval_tool() -> str
Simulated approval tool.
funcstrands-py.tests_integ.mcp.elicitation_server.server() -> None
Simulate approval through MCP elicitation.
funcstrands-py.tests_integ.mcp.task_echo_server.main(port:int) -> int
Start the task echo server.
funcstrands-py.tests_integ.memory._bedrock_kb_test_helpers.key_from_uri(uri:str) -> str
Extract the S3 object key from an ``s3://`` URI.

この情報について

掲載しているシグネチャは strands-agents/harness-sdk の公開ソースコードを Python の ast モジュールで静的解析し、引数名・デフォルト値・ 型注釈・戻り値型をそのまま抽出したものです。実装コードは保存していません。 詳しくは仕組みの解説をご覧ください。

収録ライブラリ一覧(全 805 件)へ戻る