Skip to content

An efficient and user-friendly chatbot trained on the XRP Ledger codebase to improve the developer experience on the XRP ledger.

Notifications You must be signed in to change notification settings

reapersy/XRP-Ledger-Chatbot

Repository files navigation

XRP Ledger Chatbot

This chatbot is powered by GPT-4 and trained on the XRP Ledger codebase. Use it to ask questions regarding the operations of the XRP Ledger and receive specific answers with code references. The project aims at enhancing the experience for developers working with the XRP ledger.

ChatbotUI

Prerequisites

  • Node.js (v16 or higher)
  • Yarn
  • wget (install on macOS with brew install wget)

Once the above steps are complete, load our data source.

Data Ingestion

For data ingestion, start by running the command below:

sh download.sh

This command downloads our data source (the Langchain docs in this case). Next, install dependencies and run the ingestion script:

yarn && yarn ingest

Remember, if you're using Node v16, use NODE_OPTIONS='--experimental-fetch' yarn ingest.

The script parses the data, splits text, creates embeddings, stores them in a vectorstore and saves it to the data/ directory. The Next.js server needs the data/ directory to function. Ensure you execute this step before moving to the next.

Starting the Server

To run the development server:

yarn dev

Now, open http://localhost:3000 with your browser.

Deployment

To deploy your server on Fly, employ the provided fly.toml and Dockerfile. The production version of this repo hosts on fly.

Attribution

Running on Your Example

To chat your data, you need to:

  1. Create a similar data/ directory with a vectorstore in it using your own ingestion pipeline.
  2. Customize the prompt used in pages/api/util.ts. The current setup only answers questions about LangChain. To adapt it to your data, update accordingly.

Rest assured, the server will work perfectly after these changes 😄

About

An efficient and user-friendly chatbot trained on the XRP Ledger codebase to improve the developer experience on the XRP ledger.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published