Use AI to personify books, so that you can talk to them 🙊
Last updated Dec 22, 2024
18
Stars
2
Forks
0
Issues
0
Stars/day
Attention Score
4
Topics
Language breakdown
Jupyter Notebook 99.6%
Shell 0.4%
▸ Files
click to expand
README
Talk2Book 📖
Use AI to personify books, so that you can talk to them 🙊
Notebooks
Talk2Book.ipynb
Use this to talk to '1984'. Embeddings for this book have already been created so you can use it out of the box 📦
Book2Vec.ipynb
Use this to see how embeddings for '1984' were made or create your own for another book!
Limitations
This can't yet do summaries or continue a conversaion; each question gets a single answer. Contributions for these are very welcome!Potential improvements
Save good outputs to use as examples in the prompt (few shot).How can I talk to another book?
- Create a vector store with embeddings using
Book2Vec.ipynb - Upload to https://huggingface.co as a dataset (recommended)
- Use
Talk2Book.ipynbwith the vector store you created
- Duplicate this Hugging Face Space (or just copy the code in
app.py) and change the vector store to the one you created in step 2
Contributing
- Fork
- Install requirements:
pip install -r requirements.txt(also at the top of each notebook) - Install nbdev:
pip instal nbdev - Make changes, run your notebooks
- Run
nbdevinstall_hooksto clean the notebooks (removes metadata)
- Submit your PR
Using Codespaces/VSCode
Everything you need will be installed when you open Codespaces/VSCode; specified in .devcontainer/
Notes for Codespaces:
- Currently Jupyter notebook doesn’t work on Codespaces for an unknown reason, or at least I can’t, so you’ll have to use JupyterLab
- Open with
jupyter lab --NotebookApp.allow_origin='*' --NotebookApp.ip='0.0.0.0' - For more info on using see https://code.visualstudio.com/docs/datascience/notebooks-web
🔗 More in this category