Skip to content

Commit

Permalink
Visualize the Vector embeddings in graph
Browse files Browse the repository at this point in the history
  • Loading branch information
r-manimaran committed Jul 13, 2024
1 parent 9efcc3e commit d2aee7c
Show file tree
Hide file tree
Showing 11 changed files with 600 additions and 0 deletions.
1 change: 1 addition & 0 deletions visualize-vector-embeddings/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
OPENAI_API_KEY=sk-xxx-xxxxxxxxxxxxxxxxxxxxx
162 changes: 162 additions & 0 deletions visualize-vector-embeddings/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/
cover/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.pybuilder/
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
# For a library or package, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# .python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# poetry
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
# This is especially recommended for binary packages to ensure reproducibility, and is more
# commonly ignored for libraries.
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock

# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
.pdm.toml
.pdm-python
.pdm-build/

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# pytype static type analyzer
.pytype/

# Cython debug symbols
cython_debug/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/
6 changes: 6 additions & 0 deletions visualize-vector-embeddings/data/data1.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Elmwood Banking & Trust has firmly established itself as a beacon of financial reliability and personalized service in its community. With a deep understanding of its customers' needs, Elmwood offers a plethora of financial products and services, ensuring every individual's and business's financial goals are met with precision and care.
The bank's personal loan offerings are diverse, providing financial solutions for various life events. From home renovations to unexpected expenses, Elmwood's personal loans are structured with flexibility and competitive interest rates, making them accessible to a broad range of customers. For businesses, the bank offers commercial loans that are essential for growth and expansion. These loans are tailored to each business's unique needs, whether it's for upgrading equipment, expanding operations, or increasing working capital.
Elmwood's wealth management services are a cornerstone of its offerings. The bank's financial advisors are skilled in crafting investment strategies that align with clients' long-term financial objectives. They offer guidance in portfolio management, retirement planning, and estate planning, ensuring clients' financial futures are secure.
For those looking to buy or refinance a home, Elmwood's mortgage options are comprehensive. The bank's mortgage experts work closely with clients to find the best mortgage solutions, whether it's a fixed-rate, adjustable-rate, or a more specialized mortgage product. Their goal is to make the process of home financing as seamless and straightforward as possible, providing support and advice at every step.
Elmwood Banking & Trust also places a high value on financial education. The bank regularly hosts workshops and seminars on various financial topics, from basic budgeting and savings strategies to more complex investment and tax planning concepts. These educational initiatives are part of Elmwood's commitment to empowering its customers with the knowledge to make informed financial decisions.
In addition to its financial services, Elmwood is deeply ingrained in the community. The bank supports local charities, sponsors community events, and encourages its employees to volunteer, reflecting its commitment to making a positive impact in the community it serves. This community-centric approach is what truly distinguishes Elmwood Banking & Trust as more than just a financial institution, but a pillar of support and growth in its community.
10 changes: 10 additions & 0 deletions visualize-vector-embeddings/data/data2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
La Bella Vita offers a gastronomic journey through the rich landscapes of Italian cuisine, encapsulating the essence of Italy's culinary tradition. The restaurant's ambiance, reminiscent of a rustic Italian villa, sets the stage for an authentic dining experience.
The chefs at La Bella Vita are masters of their craft, bringing generations of Italian cooking expertise to the table. The menu features a variety of regional specialties, showcasing the diversity of Italian cuisine. From the northern delicacies like risotto and polenta to the southern favorites like Neapolitan pizza and Sicilian seafood, each dish tells a story of its regional origin.
The pasta selection is a highlight of the menu, featuring classics like lasagna, ravioli, and gnocchi, each prepared with homemade pasta and cooked to perfection. The sauces, ranging from rich and creamy to light and zesty, are made with the freshest ingredients, bringing out the authentic flavors of Italy.
The meat and fish dishes are equally impressive, with offerings like osso buco, saltimbocca, and grilled branzino. These dishes are cooked with traditional methods, ensuring every bite is infused with the depth and richness of Italian culinary tradition.
La Bella Vita also prides itself on its vegetarian and vegan options, catering to all dietary preferences. Dishes like eggplant parmigiana and mushroom risotto are crafted with the same attention to detail and flavor as their meat-based counterparts.
The wine list at La Bella Vita is a carefully curated selection of Italian wines, ranging from well-known labels to hidden gems from small vineyards across Italy. The staff are knowledgeable and can recommend the perfect wine to complement each dish, enhancing the overall dining experience.
Desserts at La Bella Vita are a must-try, with a range of traditional Italian sweets. The cannoli, filled with sweet, creamy ricotta, and the affogato, a delightful blend of espresso and gelato, are perfect endings to an exquisite meal.
La Bella Vita also offers a unique dining experience with its private dining rooms and catering services. Whether it's for a special occasion, a business meeting, or a family gathering, the restaurant provides a personalized service that makes every event memorable.
The staff at La Bella Vita are the heart of the restaurant. Their passion for Italian cuisine and culture is evident in their attentive service and willingness to go above and beyond to ensure every guest has an enjoyable dining experience.
In essence, La Bella Vita is not just a restaurant; it's a destination for those who appreciate the art of Italian cuisine. It's a place where food, culture, and passion come together, creating an unforgettable dining experience that keeps guests coming back for more.
Binary file added visualize-vector-embeddings/image-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added visualize-vector-embeddings/image-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added visualize-vector-embeddings/image-3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added visualize-vector-embeddings/image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit d2aee7c

Please sign in to comment.