Skip to content

Commit

Permalink
fix: mention that the user may not be authorized
Browse files Browse the repository at this point in the history
  • Loading branch information
kenany committed Oct 3, 2024
1 parent 3c0bb72 commit 6f5a50c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,4 +87,8 @@ jobs:
if: ${{ matrix.os == 'macos-latest' }}

- name: Print help text
run: uv run python -m langchain_rag_authz --help
uses: nick-fields/[email protected]
with:
timeout_seconds: 30
max_attempts: 10
command: uv run python -m langchain_rag_authz --help
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ But they cannot query finance information:
```
$ python -m langchain_rag_authz --user alice "What is the top salary in the Engineering department?"
I don't know.
I don't know the answer to that question, and you may not be authorized to know the answer.
```

And vice versa for "bob", who is in finance but not engineering.
Expand Down
2 changes: 1 addition & 1 deletion langchain_rag_authz/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
[
(
"human",
"""You are an assistant for question-answering tasks. Use the following pieces of retrieved context to answer the question. If you don't know the answer, just say that you don't know. Use three sentences maximum and keep the answer concise.
"""You are an assistant for question-answering tasks. Use the following pieces of retrieved context to answer the question. If you don't know the answer, just say that you don't know and that the user may not be authorized to know the answer. Use three sentences maximum and keep the answer concise.
Question: {input}
Context: {context}
Answer:""",
Expand Down

0 comments on commit 6f5a50c

Please sign in to comment.