Langchain
Guide for integrating Ionic using Langchain’s ReAct Agent
Ionic Langchain
Ionic LangChain Tool
Ionic Langchain provides a wrapper around the Ionic Commerce’s SDK for use as a Tool
in a custom Langchain agent. This tool will enable e-commerce for your agent, allowing your users to ask for product recommendations and purchase products through the agent chat interface.
Langchain Template
Get started quickly using LangServe and the Ionic Shopping Assistant Template
ReAct Agent Example
Example notebook integrating Ionic using LangChain’s ReAct Agent
OpenAI Tools Agent Example
Example notebook integrating Ionic using LangChain’s OpenAI Tools Agent
Installation
This tool requires at least langchain@0.1
and can work with any greater patch release the ^0.1.x
series.
We currently support python 3.8.10 and above, but if you need support for a lower version, please open an issue and we will add support.
You can install the package from PyPI using pip
:
or poetry
:
Usage
Customizing the SDK
ionic_langchain.tool.IonicTool
’s constructor accepts an instance of ionic_langchain.tool.Ionic
, a wrapper around our SDK. ionic_langchain.tool.Ionic
, in turn accepts an instance of that SDK, so you can provide the tool with a custom configuration:
Was this page helpful?