fix: stop auto-loading context.txt into Streamlit sessions#86
fix: stop auto-loading context.txt into Streamlit sessions#86DavidJBianco wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f0601d2095
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| local_context = file.read() | ||
|
|
||
| st.session_state["local_context"] = local_context | ||
| st.session_state["local_context"] = "" |
There was a problem hiding this comment.
Restore a configurable local_context source
Setting st.session_state["local_context"] to "" here removes the only initialization path in the Streamlit app, and there is no other write path in peak_assistant/streamlit to populate that key before util/runners.py forwards it to every agent call. In practice, Streamlit sessions now always run with empty local context, so users lose the previous context-file behavior and the --context/PEAK_CONTEXT_FILE compatibility path becomes effectively unused.
Useful? React with 👍 / 👎.
|
Merged into dev via merge commit 39cb907. |
Summary
Stops
peak_assistant/streamlit/app.pyfrom automatically readingcontext.txtfrom disk and injecting it into every user session, which could forward sensitive server-side data to external LLM providers.Initializes
st.session_state["local_context"]to""instead. Users provide context explicitly via the in-UI Local Context field. Adds an inline comment explaining the security rationale.Cherry-picked from #76. Closes #75 (duplicate, identical change with a less explanatory comment).
Test plan
🤖 Generated with Claude Code