← 开源
techleadhd

chatgpt-retrieval

AI EngineeringGive agent knowledgePython
在 GitHub 打开
增长势头
+124 小时新增 Star+0.1%
1.69k
Star
761
Fork
+1
本周
3
贡献者
创建于 2023-06-19 · 更新于 2026-10-19 · 今日第 5689 名
主要开发者
techleadhdAliAbbasi2021tilenn
README

chatgpt-retrieval

Simple script to use ChatGPT on your own files.

Here's the YouTube Video.

Installation

Install Langchain and other required packages.

pip install langchain openai chromadb tiktoken unstructured

Modify constants.py.default to use your own OpenAI API key, and rename it to constants.py.

Place your own data into data/data.txt.

Example usage

Test reading data/data.txt file.

> python chatgpt.py "what is my dog's name"
Your dog's name is Sunny.

Test reading data/cat.pdf file.

> python chatgpt.py "what is my cat's name"
Your cat's name is Muffy.
排名相邻
同类项目