Update userguide notebooks, fix typos and docs updates#523
Conversation
🛡️ Jit Security Scan Results✅ No security findings were detected in this PR
Security scan by Jit
|
There was a problem hiding this comment.
Pull request overview
This PR updates RedisVL’s user guide notebooks (notably the LLM cache guide), fixes a few docstring typos, and corrects package exports/documentation to better match current project structure and tooling.
Changes:
- Fix minor Python docstring/examples and
__all__exports (redisvl/__init__.py, query/schema docstrings, query exports). - Enhance user-guide notebooks with new sections on record management and LLM cache IDs/TTL behavior.
- Update
CONTRIBUTING.mdto reflect Python 3.9+ and current formatting tooling (isort + black).
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
redisvl/schema/schema.py |
Fixes a docstring example typo for tag field creation. |
redisvl/query/query.py |
Fixes a docstring example to pass a filename string to from_yaml. |
redisvl/query/__init__.py |
Exports HybridQuery via __all__. |
redisvl/__init__.py |
Corrects export list to use __all__. |
docs/user_guide/03_llmcache.ipynb |
Adds sections on entry IDs/keys and TTL behavior; notebook outputs updated. |
docs/user_guide/01_getting_started.ipynb |
Adds a “Fetch and Manage Records” section and reorganizes subsequent content. |
CONTRIBUTING.md |
Updates minimum Python version and adjusts direct-formatting commands to isort/black. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
| "# Really try to trick it by asking around the point\n", | ||
| "# But is able to slip just under our new threshold\n", | ||
| "question = \"What is the capital city of the country in Europe that also has a city named Nice?\"\n", | ||
| "question = \"What is the capital of the country where Nice is located?\"\n", |
There was a problem hiding this comment.
Notebook committed with IndexError in cell output
High Severity
Cell 16 in 03_llmcache.ipynb was committed with an IndexError: list index out of range in its output. The cell is supposed to demonstrate that a semantically similar question ("What is the capital of the country where Nice is located?") matches the cached entry under the widened 0.5 threshold, but llmcache.check() returns an empty list. The comment says "But is able to slip just under our new threshold" — but it doesn't match. This likely broke when the embedding model was changed from redis/langcache-embed-v1 to redis/langcache-embed-v2. Users following this tutorial will see a traceback error as the expected output.
7bc2448 to
3b7fb19
Compare
3b7fb19 to
622aaa5
Compare
justin-cechmanek
left a comment
There was a problem hiding this comment.
👍🏼
All the formal fixes look good. If the notebooks run then it's all good!


Summary
This PR includes typo fixes, export corrections, and documentation enhancements for the RedisVL user guides (llmcache).
Changes
Code Fixes
redisvl/__init__.py: Fixedall→__all__(proper Python dunder variable)redisvl/query/query.py: Fixed docstring typoindex.yaml→"index.yaml"redisvl/schema/schema.py: Fixed docstring typo"tag}→"tag"}redisvl/query/__init__.py: AddedHybridQueryto__all__exportsDocumentation Updates
CONTRIBUTING.md: Updated Python version requirement from 3.8 → 3.9 and corrected linting commandsUser Guide Enhancements
01_getting_started.ipynbfetch()by IDkey()method for getting full Redis keyspaginate()andFilterQuerydrop_keys()anddrop_documents()for deletion03_llmcache.ipynbentry_idis generated (SHA256 hash of prompt + filters)entry_idandkey_index.fetch()drop(ids=[...])ordrop(keys=[...])check()adding TTL to previously-permanent entriesTesting
sentence-transformersto 5.2.3 to remove version warning in outputsNote
Low Risk
Low risk: changes are primarily documentation/notebook updates plus small, backward-compatible fixes to module exports and docstring examples.
Overview
Updates contributor and user documentation, including a refreshed
CONTRIBUTING.md(Python 3.9+ and updated UV lint/format commands) and expanded user-guide notebooks.The
01_getting_started.ipynbguide now includes a new Fetch and Manage Records section demonstratingfetch(),key(),paginate()enumeration, and record deletion viadrop_keys()/drop_documents(), with some notebook cell reordering.The
03_llmcache.ipynbguide adds explanations and examples for entry IDs vs Redis keys, targeted fetch/delete of cache entries, and detailed TTL/TTL-refresh behavior; it also updates the embedding model used in examples.Minor library cleanup fixes
__all__inredisvl/__init__.py, exportsHybridQueryfromredisvl/query/__init__.py, and corrects a couple of docstring typos inquery.pyandschema.py.Written by Cursor Bugbot for commit 622aaa5. This will update automatically on new commits. Configure here.