Ever wanted to have ChatGPT personalized with your own documents? This project lets you quickly and easily ask questions of a set of files.
Try it for yourself
This repository includes a snapshot of XetHub documentation as the default data. Navigate to the
Capsules tab and type in a question about XetHub to see how it does. Give it a shot!
Customize and remix
Ready to build your own question answerer? Use PersonalGPT as a starting point for your own app and customize away!
Install our tools and set up your account if you haven't already, then click the
Duplicate button on the top right to make a copy of this project in your account. Use the Settings tab to set visibility to Private if you want to keep your PersonalGPT to yourself.
Our PersonalGPT uses OpenAI and LangChain to provide question answering. Create an OpenAI account and go to the API keys page to generate your key. Export the key as an environment variable to ensures that you won't accidentally leak it if you share your repository:
export OPENAI_API_KEY="<your OpenAI API key>"
Update this repository locally with your chosen files. Start by copying the repository to your machine:
Using Git-Xet (recommended):
git-xet clone https://<your username>/PersonalGPT.git cd PersonalGPT
Using Xet CLI:
xet cp -r xet://<your username>/PersonalGPT/main PersonalGPT cd PersonalGPT
This app was developed with Python 3.9. Set up your Python environment:
# create and activate a virtual environment python -m venv venv source venv/bin/activate # install dependencies pip install -r requirements.txt
Replace the default files in the
data/directory with any set of text files.
Train your app with your new data.
Run your app locally.
If everything looks good, commit your changes:
- Using Git-Xet (recommended):
git add . git commit -am "Update app with my files" git push
- Using Xet CLI:
xet cp -r PersonalGPT xet://<your username>/PersonalGPT/main -m "Update app with my files"
Launch and share
Ready to share your question answerer with a wider audience? Capsules make it easy to deploy Python apps on XetHub.
Once your project is ready, go to the
Capsules tab and click
Change under the App Settings box. This will bring up a Settings page where you can add your OpenAI API key as a secret. To print out your API key environment variable, run:
Update Settings and then launch your capsule. You can easily share capsules in public repositories with others with their URLs or by clicking Share Capsule under the branch dropdown menu. To add others to a private repository to add more documents, invite a collaborator.
|File List||Total items: 8|
|Name||Last Commit||Size||Last Modified|