id stringlengths 14 15 | text stringlengths 44 2.47k | source stringlengths 61 181 |
|---|---|---|
9352da846865-2 | Generate a JSON representation of the model, include and exclude arguments as per dict().
encoder is an optional function to supply as default to json.dumps(), other arguments as per json.dumps().
classmethod parse_file(path: Union[str, Path], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol... | https://api.python.langchain.com/en/latest/agents/langchain.agents.self_ask_with_search.base.SelfAskWithSearchAgent.html |
9352da846865-3 | classmethod schema_json(*, by_alias: bool = True, ref_template: unicode = '#/definitions/{model}', **dumps_kwargs: Any) → unicode¶
tool_run_logging_kwargs() → Dict¶
classmethod update_forward_refs(**localns: Any) → None¶
Try to update ForwardRefs on fields based on this Model, globalns and localns.
classmethod validate... | https://api.python.langchain.com/en/latest/agents/langchain.agents.self_ask_with_search.base.SelfAskWithSearchAgent.html |
9cf891774116-0 | langchain.agents.agent_toolkits.github.toolkit.GitHubToolkit¶
class langchain.agents.agent_toolkits.github.toolkit.GitHubToolkit[source]¶
Bases: BaseToolkit
GitHub Toolkit.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.github.toolkit.GitHubToolkit.html |
9cf891774116-1 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.github.toolkit.GitHubToolkit.html |
9cf891774116-2 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmet... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.github.toolkit.GitHubToolkit.html |
4ddf9bdfef71-0 | langchain.agents.load_tools.load_huggingface_tool¶
langchain.agents.load_tools.load_huggingface_tool(task_or_repo_id: str, model_repo_id: Optional[str] = None, token: Optional[str] = None, remote: bool = False, **kwargs: Any) → BaseTool[source]¶
Loads a tool from the HuggingFace Hub.
Parameters
task_or_repo_id – Task o... | https://api.python.langchain.com/en/latest/agents/langchain.agents.load_tools.load_huggingface_tool.html |
bda00bcfd9ce-0 | langchain.agents.agent_toolkits.ainetwork.toolkit.AINetworkToolkit¶
class langchain.agents.agent_toolkits.ainetwork.toolkit.AINetworkToolkit[source]¶
Bases: BaseToolkit
Toolkit for interacting with AINetwork Blockchain.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationErr... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.ainetwork.toolkit.AINetworkToolkit.html |
bda00bcfd9ce-1 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.ainetwork.toolkit.AINetworkToolkit.html |
bda00bcfd9ce-2 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmet... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.ainetwork.toolkit.AINetworkToolkit.html |
aadf8f760912-0 | langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing¶
class langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing[source]¶
Bases: BaseRequestsTool, BaseTool
Requests POST tool with LLM-instructed extraction of truncated responses.
Create a new model by parsing and validating... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
aadf8f760912-1 | This metadata will be associated with each call to this tool,
and passed as arguments to the handlers defined in callbacks.
You can use these to eg identify a specific instance of a tool with its use case.
param name: str = 'requests_post'¶
Tool name.
param requests_wrapper: TextRequestsWrapper [Required]¶
param respon... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
aadf8f760912-2 | Subclasses should override this method if they can run asynchronously.
async arun(tool_input: Union[str, Dict], verbose: Optional[bool] = None, start_color: Optional[str] = 'green', color: Optional[str] = 'green', callbacks: Optional[Union[List[BaseCallbackHandler], BaseCallbackManager]] = None, *, tags: Optional[List[... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
aadf8f760912-3 | Default implementation of atransform, which buffers input and calls astream.
Subclasses should override this method if they can start producing output while
input is still being generated.
batch(inputs: List[Input], config: Optional[Union[RunnableConfig, List[RunnableConfig]]] = None, *, return_exceptions: bool = False... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
aadf8f760912-4 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
aadf8f760912-5 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
run(tool_input: Union[str, Dict], verbose: Optional[bool] = None, start_color: Optional[str] = 'green', color: Op... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
aadf8f760912-6 | Bind config to a Runnable, returning a new Runnable.
with_fallbacks(fallbacks: ~typing.Sequence[~langchain.schema.runnable.base.Runnable[~langchain.schema.runnable.utils.Input, ~langchain.schema.runnable.utils.Output]], *, exceptions_to_handle: ~typing.Tuple[~typing.Type[BaseException], ...] = (<class 'Exception'>,)) →... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPostToolWithParsing.html |
5596b2b97714-0 | langchain.agents.agent_toolkits.vectorstore.toolkit.VectorStoreToolkit¶
class langchain.agents.agent_toolkits.vectorstore.toolkit.VectorStoreToolkit[source]¶
Bases: BaseToolkit
Toolkit for interacting with a Vector Store.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationE... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.vectorstore.toolkit.VectorStoreToolkit.html |
5596b2b97714-1 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.vectorstore.toolkit.VectorStoreToolkit.html |
5596b2b97714-2 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmet... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.vectorstore.toolkit.VectorStoreToolkit.html |
92f36e177949-0 | langchain.agents.mrkl.base.ZeroShotAgent¶
class langchain.agents.mrkl.base.ZeroShotAgent[source]¶
Bases: Agent
Agent for the MRKL chain.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
param allowed_tools: O... | https://api.python.langchain.com/en/latest/agents/langchain.agents.mrkl.base.ZeroShotAgent.html |
92f36e177949-1 | Parameters
include – fields to include in new model
exclude – fields to exclude from new model, as with values this takes precedence over include
update – values to change/add in the new model. Note: the data is not validated before creating
the new model: you should trust this data
deep – set to True to make a deep co... | https://api.python.langchain.com/en/latest/agents/langchain.agents.mrkl.base.ZeroShotAgent.html |
92f36e177949-2 | dict(**kwargs: Any) → Dict¶
Return dictionary representation of agent.
classmethod from_llm_and_tools(llm: BaseLanguageModel, tools: Sequence[BaseTool], callback_manager: Optional[BaseCallbackManager] = None, output_parser: Optional[AgentOutputParser] = None, prefix: str = 'Answer the following questions as best you ca... | https://api.python.langchain.com/en/latest/agents/langchain.agents.mrkl.base.ZeroShotAgent.html |
92f36e177949-3 | Create the full inputs for the LLMChain from intermediate steps.
json(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, exclude_defaults... | https://api.python.langchain.com/en/latest/agents/langchain.agents.mrkl.base.ZeroShotAgent.html |
92f36e177949-4 | Return response when agent has been stopped due to max iterations.
save(file_path: Union[Path, str]) → None¶
Save the agent.
Parameters
file_path – Path to file to save the agent to.
Example:
.. code-block:: python
# If working with agent executor
agent.agent.save(file_path=”path/agent.yaml”)
classmethod schema(by_alia... | https://api.python.langchain.com/en/latest/agents/langchain.agents.mrkl.base.ZeroShotAgent.html |
4316836ae98e-0 | langchain.agents.tools.InvalidTool¶
class langchain.agents.tools.InvalidTool[source]¶
Bases: BaseTool
Tool that is run when invalid tool name is encountered by agent.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
4316836ae98e-1 | These tags will be associated with each call to this tool,
and passed as arguments to the handlers defined in callbacks.
You can use these to eg identify a specific instance of a tool with its use case.
param verbose: bool = False¶
Whether to log the tool’s progress.
__call__(tool_input: str, callbacks: Optional[Union[... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
4316836ae98e-2 | Subclasses should override this method if they support streaming output.
async astream_log(input: Any, config: Optional[RunnableConfig] = None, *, include_names: Optional[Sequence[str]] = None, include_types: Optional[Sequence[str]] = None, include_tags: Optional[Sequence[str]] = None, exclude_names: Optional[Sequence[... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
4316836ae98e-3 | Creates a new model setting __dict__ and __fields_set__ from trusted or pre-validated data.
Default values are respected, but no other validation is performed.
Behaves as if Config.extra = ‘allow’ was set since it adds all passed values
copy(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclu... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
4316836ae98e-4 | json(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, encoder: Optional[Cal... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
4316836ae98e-5 | Run the tool.
classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmethod schema_json(*, by_alias: bool = True, ref_template: unicode = '#/definitions/{model}', **dumps_kwargs: Any) → unicode¶
stream(input: Input, config: Optional[RunnableConfig] = None, **kwargs... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
4316836ae98e-6 | property InputType: Type[langchain.schema.runnable.utils.Input]¶
property OutputType: Type[langchain.schema.runnable.utils.Output]¶
property args: dict¶
property input_schema: Type[pydantic.main.BaseModel]¶
The tool’s input schema.
property is_single_input: bool¶
Whether the tool only accepts a single input.
property o... | https://api.python.langchain.com/en/latest/agents/langchain.agents.tools.InvalidTool.html |
6b89b0bbae73-0 | langchain.agents.agent.Agent¶
class langchain.agents.agent.Agent[source]¶
Bases: BaseSingleActionAgent
Agent that calls the language model and deciding the action.
This is driven by an LLMChain. The prompt in the LLMChain MUST include
a variable called “agent_scratchpad” where the agent can put its
intermediary work.
C... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.Agent.html |
6b89b0bbae73-1 | Behaves as if Config.extra = ‘allow’ was set since it adds all passed values
copy(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, update: Optional[DictStrAny] = None, deep: bool = False) → Model¶
Duplicate a model, optionally... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.Agent.html |
6b89b0bbae73-2 | Create the full inputs for the LLMChain from intermediate steps.
json(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, exclude_defaults... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.Agent.html |
6b89b0bbae73-3 | Return response when agent has been stopped due to max iterations.
save(file_path: Union[Path, str]) → None¶
Save the agent.
Parameters
file_path – Path to file to save the agent to.
Example:
.. code-block:: python
# If working with agent executor
agent.agent.save(file_path=”path/agent.yaml”)
classmethod schema(by_alia... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.Agent.html |
2d37e14af552-0 | langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing¶
class langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing[source]¶
Bases: BaseRequestsTool, BaseTool
Requests PUT tool with LLM-instructed extraction of truncated responses.
Create a new model by parsing and validating in... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
2d37e14af552-1 | This metadata will be associated with each call to this tool,
and passed as arguments to the handlers defined in callbacks.
You can use these to eg identify a specific instance of a tool with its use case.
param name: str = 'requests_put'¶
Tool name.
param requests_wrapper: TextRequestsWrapper [Required]¶
param respons... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
2d37e14af552-2 | Subclasses should override this method if they can run asynchronously.
async arun(tool_input: Union[str, Dict], verbose: Optional[bool] = None, start_color: Optional[str] = 'green', color: Optional[str] = 'green', callbacks: Optional[Union[List[BaseCallbackHandler], BaseCallbackManager]] = None, *, tags: Optional[List[... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
2d37e14af552-3 | Default implementation of atransform, which buffers input and calls astream.
Subclasses should override this method if they can start producing output while
input is still being generated.
batch(inputs: List[Input], config: Optional[Union[RunnableConfig, List[RunnableConfig]]] = None, *, return_exceptions: bool = False... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
2d37e14af552-4 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
2d37e14af552-5 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
run(tool_input: Union[str, Dict], verbose: Optional[bool] = None, start_color: Optional[str] = 'green', color: Op... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
2d37e14af552-6 | Bind config to a Runnable, returning a new Runnable.
with_fallbacks(fallbacks: ~typing.Sequence[~langchain.schema.runnable.base.Runnable[~langchain.schema.runnable.utils.Input, ~langchain.schema.runnable.utils.Output]], *, exceptions_to_handle: ~typing.Tuple[~typing.Type[BaseException], ...] = (<class 'Exception'>,)) →... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.planner.RequestsPutToolWithParsing.html |
641191195803-0 | langchain.agents.mrkl.base.ChainConfig¶
class langchain.agents.mrkl.base.ChainConfig(action_name: str, action: Callable, action_description: str)[source]¶
Configuration for chain to use in MRKL system.
Parameters
action_name – Name of the action.
action – Action function to call.
action_description – Description of the... | https://api.python.langchain.com/en/latest/agents/langchain.agents.mrkl.base.ChainConfig.html |
b592ac39ffd5-0 | langchain.agents.agent.RunnableAgent¶
class langchain.agents.agent.RunnableAgent[source]¶
Bases: BaseSingleActionAgent
Agent powered by runnables.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
param runnab... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.RunnableAgent.html |
b592ac39ffd5-1 | Parameters
include – fields to include in new model
exclude – fields to exclude from new model, as with values this takes precedence over include
update – values to change/add in the new model. Note: the data is not validated before creating
the new model: you should trust this data
deep – set to True to make a deep co... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.RunnableAgent.html |
b592ac39ffd5-2 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
plan(intermediate_steps: List[Tuple[AgentAction, str]], callbacks: Optional[Union[List[BaseCallbackHandler], Base... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.RunnableAgent.html |
b592ac39ffd5-3 | property input_keys: List[str]¶
Return the input keys.
Returns
List of input keys.
property return_values: List[str]¶
Return values of the agent. | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent.RunnableAgent.html |
a63bbf0b9d95-0 | langchain.agents.output_parsers.json.JSONAgentOutputParser¶
class langchain.agents.output_parsers.json.JSONAgentOutputParser[source]¶
Bases: AgentOutputParser
Parses tool invocations and final answers in XML format.
Expects output to be in one of two formats.
If the output signals that an action should be taken,
should... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
a63bbf0b9d95-1 | Parameters
text – String output of a language model.
Returns
Structured output.
async aparse_result(result: List[Generation], *, partial: bool = False) → T¶
Parse a list of candidate model Generations into a specific format.
The return value is parsed from only the first Generation in the result, whichis assumed to be ... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
a63bbf0b9d95-2 | Default implementation of atransform, which buffers input and calls astream.
Subclasses should override this method if they can start producing output while
input is still being generated.
batch(inputs: List[Input], config: Optional[Union[RunnableConfig, List[RunnableConfig]]] = None, *, return_exceptions: bool = False... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
a63bbf0b9d95-3 | Return dictionary representation of output parser.
classmethod from_orm(obj: Any) → Model¶
get_format_instructions() → str¶
Instructions on how the LLM output should be formatted.
classmethod get_lc_namespace() → List[str]¶
Get the namespace of the langchain object.
For example, if the class is langchain.llms.openai.Op... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
a63bbf0b9d95-4 | Parse text into agent action/finish.
classmethod parse_file(path: Union[str, Path], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = No... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
a63bbf0b9d95-5 | Default implementation of stream, which calls invoke.
Subclasses should override this method if they support streaming output.
to_json() → Union[SerializedConstructor, SerializedNotImplemented]¶
to_json_not_implemented() → SerializedNotImplemented¶
transform(input: Iterator[Input], config: Optional[RunnableConfig] = No... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
a63bbf0b9d95-6 | These attributes must be accepted by the constructor.
property lc_secrets: Dict[str, str]¶
A map of constructor argument names to secret ids.
For example,{“openai_api_key”: “OPENAI_API_KEY”}
property output_schema: Type[pydantic.main.BaseModel]¶ | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.json.JSONAgentOutputParser.html |
8a50c1ffa44a-0 | langchain.agents.agent_toolkits.jira.toolkit.JiraToolkit¶
class langchain.agents.agent_toolkits.jira.toolkit.JiraToolkit[source]¶
Bases: BaseToolkit
Jira Toolkit.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid mod... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.jira.toolkit.JiraToolkit.html |
8a50c1ffa44a-1 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.jira.toolkit.JiraToolkit.html |
8a50c1ffa44a-2 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmet... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.jira.toolkit.JiraToolkit.html |
d117e0e74b12-0 | langchain.agents.initialize.initialize_agent¶
langchain.agents.initialize.initialize_agent(tools: Sequence[BaseTool], llm: BaseLanguageModel, agent: Optional[AgentType] = None, callback_manager: Optional[BaseCallbackManager] = None, agent_path: Optional[str] = None, agent_kwargs: Optional[dict] = None, *, tags: Optiona... | https://api.python.langchain.com/en/latest/agents/langchain.agents.initialize.initialize_agent.html |
d117e0e74b12-1 | Log, Trace, and Monitor
Portkey
Jira
Document Comparison
Azure Cognitive Services
Natural Language APIs
Gmail
Github
Google Drive tool
AINetwork
PlayWright Browser
Office365
MultiOn
Amadeus
Gitlab
Bittensor
Amazon API Gateway
Debugging
LangSmith Walkthrough
Hugging Face Prompt Injection Identification
Comparing Chain O... | https://api.python.langchain.com/en/latest/agents/langchain.agents.initialize.initialize_agent.html |
6f15f6eb0de4-0 | langchain.agents.agent_toolkits.spark_sql.toolkit.SparkSQLToolkit¶
class langchain.agents.agent_toolkits.spark_sql.toolkit.SparkSQLToolkit[source]¶
Bases: BaseToolkit
Toolkit for interacting with Spark SQL.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the inp... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.spark_sql.toolkit.SparkSQLToolkit.html |
6f15f6eb0de4-1 | deep – set to True to make a deep copy of the model
Returns
new model instance
dict(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, by_alias: bool = False, skip_defaults: Optional[bool] = None, exclude_unset: bool = False, ex... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.spark_sql.toolkit.SparkSQLToolkit.html |
6f15f6eb0de4-2 | classmethod parse_obj(obj: Any) → Model¶
classmethod parse_raw(b: Union[str, bytes], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: Protocol = None, allow_pickle: bool = False) → Model¶
classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmet... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.spark_sql.toolkit.SparkSQLToolkit.html |
7c08ba39105c-0 | langchain.agents.agent_toolkits.openapi.base.create_openapi_agent¶ | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.base.create_openapi_agent.html |
7c08ba39105c-1 | langchain.agents.agent_toolkits.openapi.base.create_openapi_agent(llm: BaseLanguageModel, toolkit: OpenAPIToolkit, callback_manager: Optional[BaseCallbackManager] = None, prefix: str = "You are an agent designed to answer questions by making web requests to an API given the openapi spec.\n\nIf the question does not see... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.base.create_openapi_agent.html |
7c08ba39105c-2 | Input: the input to the action\nObservation: the result of the action\n... (this Thought/Action/Action Input/Observation can repeat N times)\nThought: I now know the final answer\nFinal Answer: the final answer to the original input question', input_variables: Optional[List[str]] = None, max_iterations: Optional[int] =... | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.base.create_openapi_agent.html |
7c08ba39105c-3 | Construct an OpenAPI agent from an LLM and tools.
Examples using create_openapi_agent¶
OpenAPI | https://api.python.langchain.com/en/latest/agents/langchain.agents.agent_toolkits.openapi.base.create_openapi_agent.html |
9b810cd0785c-0 | langchain.agents.output_parsers.self_ask.SelfAskOutputParser¶
class langchain.agents.output_parsers.self_ask.SelfAskOutputParser[source]¶
Bases: AgentOutputParser
Parses self-ask style LLM calls.
Expects output to be in one of two formats.
If the output signals that an action should be taken,
should be in the below for... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
9b810cd0785c-1 | async aparse(text: str) → T¶
Parse a single string model output into some structure.
Parameters
text – String output of a language model.
Returns
Structured output.
async aparse_result(result: List[Generation], *, partial: bool = False) → T¶
Parse a list of candidate model Generations into a specific format.
The return... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
9b810cd0785c-2 | The jsonpatch ops can be applied in order to construct state.
async atransform(input: AsyncIterator[Input], config: Optional[RunnableConfig] = None, **kwargs: Optional[Any]) → AsyncIterator[Output]¶
Default implementation of atransform, which buffers input and calls astream.
Subclasses should override this method if th... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
9b810cd0785c-3 | the new model: you should trust this data
deep – set to True to make a deep copy of the model
Returns
new model instance
dict(**kwargs: Any) → Dict¶
Return dictionary representation of output parser.
classmethod from_orm(obj: Any) → Model¶
get_format_instructions() → str¶
Instructions on how the LLM output should be fo... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
9b810cd0785c-4 | Return a new Runnable that maps a list of inputs to a list of outputs,
by calling invoke() with each input.
parse(text: str) → Union[AgentAction, AgentFinish][source]¶
Parse text into agent action/finish.
classmethod parse_file(path: Union[str, Path], *, content_type: unicode = None, encoding: unicode = 'utf8', proto: ... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
9b810cd0785c-5 | stream(input: Input, config: Optional[RunnableConfig] = None, **kwargs: Optional[Any]) → Iterator[Output]¶
Default implementation of stream, which calls invoke.
Subclasses should override this method if they support streaming output.
to_json() → Union[SerializedConstructor, SerializedNotImplemented]¶
to_json_not_implem... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
9b810cd0785c-6 | property lc_attributes: Dict¶
List of attribute names that should be included in the serialized kwargs.
These attributes must be accepted by the constructor.
property lc_secrets: Dict[str, str]¶
A map of constructor argument names to secret ids.
For example,{“openai_api_key”: “OPENAI_API_KEY”}
property output_schema: T... | https://api.python.langchain.com/en/latest/agents/langchain.agents.output_parsers.self_ask.SelfAskOutputParser.html |
90746d29595e-0 | langchain.runnables.openai_functions.OpenAIFunction¶
class langchain.runnables.openai_functions.OpenAIFunction[source]¶
A function description for ChatOpenAI
Attributes
name
The name of the function.
description
The description of the function.
parameters
The parameters to the function.
Methods
__init__(*args, **kwargs... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunction.html |
90746d29595e-1 | items() → a set-like object providing a view on D's items¶
keys() → a set-like object providing a view on D's keys¶
pop(k[, d]) → v, remove specified key and return the corresponding value.¶
If the key is not found, return the default if given; otherwise,
raise a KeyError.
popitem()¶
Remove and return a (key, value) pa... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunction.html |
8c1815e204d7-0 | langchain.runnables.openai_functions.OpenAIFunctionsRouter¶
class langchain.runnables.openai_functions.OpenAIFunctionsRouter[source]¶
Bases: RunnableBinding[ChatGeneration, Any]
A runnable that routes to the selected function.
Create a new model by parsing and validating input data from keyword arguments.
Raises Valida... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunctionsRouter.html |
8c1815e204d7-1 | Subclasses should override this method if they support streaming output.
async astream_log(input: Any, config: Optional[RunnableConfig] = None, *, include_names: Optional[Sequence[str]] = None, include_types: Optional[Sequence[str]] = None, include_tags: Optional[Sequence[str]] = None, exclude_names: Optional[Sequence[... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunctionsRouter.html |
8c1815e204d7-2 | Creates a new model setting __dict__ and __fields_set__ from trusted or pre-validated data.
Default values are respected, but no other validation is performed.
Behaves as if Config.extra = ‘allow’ was set since it adds all passed values
copy(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclu... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunctionsRouter.html |
8c1815e204d7-3 | namespace is [“langchain”, “llms”, “openai”]
invoke(input: Input, config: Optional[RunnableConfig] = None, **kwargs: Optional[Any]) → Output¶
classmethod is_lc_serializable() → bool¶
Is this class serializable?
json(*, include: Optional[Union[AbstractSetIntStr, MappingIntStrAny]] = None, exclude: Optional[Union[Abstrac... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunctionsRouter.html |
8c1815e204d7-4 | classmethod schema(by_alias: bool = True, ref_template: unicode = '#/definitions/{model}') → DictStrAny¶
classmethod schema_json(*, by_alias: bool = True, ref_template: unicode = '#/definitions/{model}', **dumps_kwargs: Any) → unicode¶
stream(input: Input, config: Optional[RunnableConfig] = None, **kwargs: Optional[Any... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunctionsRouter.html |
8c1815e204d7-5 | property InputType: type[Input]¶
property OutputType: type[Output]¶
property input_schema: Type[pydantic.main.BaseModel]¶
property lc_attributes: Dict¶
List of attribute names that should be included in the serialized kwargs.
These attributes must be accepted by the constructor.
property lc_secrets: Dict[str, str]¶
A m... | https://api.python.langchain.com/en/latest/runnables/langchain.runnables.openai_functions.OpenAIFunctionsRouter.html |
2d89faddadce-0 | All modules for which code is available
langchain.adapters.openai
langchain.agents.agent
langchain.agents.agent_iterator
langchain.agents.agent_toolkits.ainetwork.toolkit
langchain.agents.agent_toolkits.amadeus.toolkit
langchain.agents.agent_toolkits.azure_cognitive_services
langchain.agents.agent_toolkits.base
langcha... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-1 | langchain.agents.agent_toolkits.sql.base
langchain.agents.agent_toolkits.sql.toolkit
langchain.agents.agent_toolkits.vectorstore.base
langchain.agents.agent_toolkits.vectorstore.toolkit
langchain.agents.agent_toolkits.xorbits.base
langchain.agents.agent_toolkits.zapier.toolkit
langchain.agents.agent_types
langchain.age... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-2 | langchain.cache
langchain.callbacks.aim_callback
langchain.callbacks.argilla_callback
langchain.callbacks.arize_callback
langchain.callbacks.arthur_callback
langchain.callbacks.base
langchain.callbacks.clearml_callback
langchain.callbacks.comet_ml_callback
langchain.callbacks.confident_callback
langchain.callbacks.cont... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-3 | langchain.chains.combine_documents.refine
langchain.chains.combine_documents.stuff
langchain.chains.constitutional_ai.base
langchain.chains.constitutional_ai.models
langchain.chains.conversation.base
langchain.chains.conversational_retrieval.base
langchain.chains.elasticsearch_database.base
langchain.chains.example_gen... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-4 | langchain.chains.prompt_selector
langchain.chains.qa_generation.base
langchain.chains.qa_with_sources.base
langchain.chains.qa_with_sources.loading
langchain.chains.qa_with_sources.retrieval
langchain.chains.qa_with_sources.vector_db
langchain.chains.query_constructor.base
langchain.chains.query_constructor.ir
langchai... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-5 | langchain.chat_models.promptlayer_openai
langchain.chat_models.vertexai
langchain.docstore.arbitrary_fn
langchain.docstore.base
langchain.docstore.in_memory
langchain.docstore.wikipedia
langchain.document_loaders.acreom
langchain.document_loaders.airbyte
langchain.document_loaders.airbyte_json
langchain.document_loader... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-6 | langchain.document_loaders.duckdb_loader
langchain.document_loaders.email
langchain.document_loaders.embaas
langchain.document_loaders.epub
langchain.document_loaders.etherscan
langchain.document_loaders.evernote
langchain.document_loaders.excel
langchain.document_loaders.facebook_chat
langchain.document_loaders.fauna
... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-7 | langchain.document_loaders.obs_directory
langchain.document_loaders.obs_file
langchain.document_loaders.obsidian
langchain.document_loaders.odt
langchain.document_loaders.onedrive
langchain.document_loaders.onedrive_file
langchain.document_loaders.open_city_data
langchain.document_loaders.org_mode
langchain.document_lo... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-8 | langchain.document_loaders.stripe
langchain.document_loaders.telegram
langchain.document_loaders.tencent_cos_directory
langchain.document_loaders.tencent_cos_file
langchain.document_loaders.tensorflow_datasets
langchain.document_loaders.text
langchain.document_loaders.tomarkdown
langchain.document_loaders.toml
langchai... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-9 | langchain.embeddings.fake
langchain.embeddings.google_palm
langchain.embeddings.gpt4all
langchain.embeddings.gradient_ai
langchain.embeddings.huggingface
langchain.embeddings.huggingface_hub
langchain.embeddings.javelin_ai_gateway
langchain.embeddings.jina
langchain.embeddings.llamacpp
langchain.embeddings.llm_rails
la... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-10 | langchain.graphs.neptune_graph
langchain.graphs.networkx_graph
langchain.graphs.rdf_graph
langchain.hub
langchain.indexes.base
langchain.indexes.graph
langchain.indexes.vectorstore
langchain.llms.ai21
langchain.llms.aleph_alpha
langchain.llms.amazon_api_gateway
langchain.llms.anthropic
langchain.llms.anyscale
langchain... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-11 | langchain.llms.minimax
langchain.llms.mlflow_ai_gateway
langchain.llms.modal
langchain.llms.mosaicml
langchain.llms.nlpcloud
langchain.llms.octoai_endpoint
langchain.llms.ollama
langchain.llms.opaqueprompts
langchain.llms.openai
langchain.llms.openllm
langchain.llms.openlm
langchain.llms.petals
langchain.llms.pipelinea... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-12 | langchain.memory.chat_message_histories.sql
langchain.memory.chat_message_histories.streamlit
langchain.memory.chat_message_histories.xata
langchain.memory.chat_message_histories.zep
langchain.memory.combined
langchain.memory.entity
langchain.memory.kg
langchain.memory.motorhead_memory
langchain.memory.readonly
langcha... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-13 | langchain.retrievers.databerry
langchain.retrievers.docarray
langchain.retrievers.document_compressors.base
langchain.retrievers.document_compressors.chain_extract
langchain.retrievers.document_compressors.chain_filter
langchain.retrievers.document_compressors.cohere_rerank
langchain.retrievers.document_compressors.emb... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-14 | langchain.retrievers.self_query.weaviate
langchain.retrievers.svm
langchain.retrievers.tfidf
langchain.retrievers.time_weighted_retriever
langchain.retrievers.vespa_retriever
langchain.retrievers.weaviate_hybrid_search
langchain.retrievers.web_research
langchain.retrievers.wikipedia
langchain.retrievers.zep
langchain.r... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-15 | langchain.tools.amadeus.base
langchain.tools.amadeus.closest_airport
langchain.tools.amadeus.flight_search
langchain.tools.amadeus.utils
langchain.tools.arxiv.tool
langchain.tools.azure_cognitive_services.form_recognizer
langchain.tools.azure_cognitive_services.image_analysis
langchain.tools.azure_cognitive_services.sp... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-16 | langchain.tools.google_search.tool
langchain.tools.google_serper.tool
langchain.tools.graphql.tool
langchain.tools.human.tool
langchain.tools.ifttt
langchain.tools.interaction.tool
langchain.tools.jira.tool
langchain.tools.json.tool
langchain.tools.metaphor_search.tool
langchain.tools.multion.create_session
langchain.t... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-17 | langchain.utilities.alpha_vantage
langchain.utilities.apify
langchain.utilities.arxiv
langchain.utilities.awslambda
langchain.utilities.bash
langchain.utilities.bibtex
langchain.utilities.bing_search
langchain.utilities.brave_search
langchain.utilities.dalle_image_generator
langchain.utilities.dataforseo_api_search
lan... | https://api.python.langchain.com/en/latest/_modules/index.html |
2d89faddadce-18 | langchain.vectorstores.awadb
langchain.vectorstores.azuresearch
langchain.vectorstores.bageldb
langchain.vectorstores.cassandra
langchain.vectorstores.chroma
langchain.vectorstores.clarifai
langchain.vectorstores.clickhouse
langchain.vectorstores.dashvector
langchain.vectorstores.deeplake
langchain.vectorstores.dingo
l... | https://api.python.langchain.com/en/latest/_modules/index.html |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.