Zettel LLM leverage LLMs and vector embeddings to automatically assign labels to notes within a zettelkasten system. For a more detailed guide, check out the Simple Manual.
-
Clone the Repository
git clone https://github.com/przadka/zettel-llm
-
Navigate to the Project Directory
cd zettel-llm
-
Activate the Virtual Environment (Make sure you have
virtualenvwrapper
installed)workon zettel-llm
-
Install Dependencies
pip install -r requirements.txt
-
Prepare Your Documents:
- Place your documents in the
documents
directory. - Currently, the system assumes documents are in CSV format.
- Place your documents in the
Ensure you have the following CSV files in the documents/
directory:
notions.csv
: Contains the notions that the system will embed.train_data.csv
: Contains the quotes and associated metadata.
For details on the expected structure of these CSV files, please refer to the Simple Manual.
Run the initialize_chroma_db.py
script. This will ensure the presence of the 'zettelkasten' collection in the specified database and begin the querying process.
python initialize_chroma_db.py
$ rm -rf chroma.db
Initializing a new database incurs a small cost. Always ensure you're aware of any associated expenses before performing this action.
Execute the main.py
script to search for specific texts within the 'zettelkasten' collection.
python main.py
Before using the scripts, configure the necessary environment variables:
OPENAI_API_KEY
: Your OpenAI API key, required for the embedding function.
You can either export this variable directly in your shell or use an .env
file.
This project is open-source and licensed under the MIT License.