You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add langchain-flan example (Harithalakshmikt) - #22
Adds a local RAG example using LangChain, FAISS and google/flan-t5-base,
with check_with_evidence() and an NLI-based compare_fn
(cross-encoder/nli-deberta-v3-base).
Tested model: google/flan-t5-base (local, no API key).
Includes a deliberately wrong answer (BLOCKED) and a correct control.
RESULTS.md reports the failures honestly: the compare_fn is over-strict
and blocks some correct answers.
Hi @Vedantgitbot, I've opened a PR for this example: (#22)
)
It uses LangChain + FAISS + google/flan-t5-base (local, no API key) with check_with_evidence() and an NLI-based compare_fn. It includes a deliberately wrong answer (BLOCKED) and a correct control answer. RESULTS.md documents the failures honestly, including false blocks from the over-strict compare_fn.
Thanks @Harithalakshmikt Great writeup, especially the NLI comparator and false-block findings. Before merging, please fix the docstring mismatch and use pip install boothpy instead of -e .. Optional: try chunk_size=100 and add a default question for reproducibility. #18 on compare_fn examples could be a great next step!
Thanks @Vedantgitbot! Pushed the changes: the docstring now matches the script (two hardcoded checks, one wrong and one correct), the install line is pip install boothpy, and I added a default question (press Enter). I left chunk_size unchanged because changing it would invalidate the recorded results; happy to try it as a follow-up.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a local RAG example using LangChain, FAISS and google/flan-t5-base,
with check_with_evidence() and an NLI-based compare_fn
(cross-encoder/nli-deberta-v3-base).
Tested model: google/flan-t5-base (local, no API key).
Includes a deliberately wrong answer (BLOCKED) and a correct control.
RESULTS.md reports the failures honestly: the compare_fn is over-strict
and blocks some correct answers.
Related to #2