Add configurable suggested questions after answer via environment variables - #1
Draft
f4844844235869 with Copilot wants to merge 2 commits into
Draft
Add configurable suggested questions after answer via environment variables#1f4844844235869 with Copilot wants to merge 2 commits into
f4844844235869 with Copilot wants to merge 2 commits into
Conversation
…ustomization Co-authored-by: f4844844235869 <87220135+f4844844235869@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add overview of capabilities and features
Add configurable suggested questions after answer via environment variables
Mar 15, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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 operator-level control over the "Suggested Questions After Answer" feature prompt and LLM parameters, enabling deployment-specific customization without code changes.
Summary
The suggested questions feature previously used a hardcoded prompt and fixed LLM parameters. This change exposes three environment variables to override them at deploy time, plus adds comprehensive tests for the output parser and parameter propagation.
New environment variables (
api/.env.example):Implementation (
api/core/llm_generator/prompts.py):SUGGESTED_QUESTIONS_AFTER_ANSWER_INSTRUCTION_PROMPTnow reads fromSUGGESTED_QUESTIONS_PROMPTenv var with the original prompt as fallbackSUGGESTED_QUESTIONS_MAX_TOKENS/SUGGESTED_QUESTIONS_TEMPERATUREsimilarly env-drivenTests added:
test_suggested_questions_after_answer.py— 12 tests coveringSuggestedQuestionsAfterAnswerOutputParser.parse(): valid JSON, embedded JSON, empty/invalid arrays, non-string element filtering, multiline, Chinese text, and custom prompt patchingtest_llm_generator.pyverifyingmax_tokensandtemperatureare correctly forwarded to the LLM invoke callScreenshots
Checklist
make lintandmake type-check(backend) andcd web && npx lint-staged(frontend) to appease the lint godsWarning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
pkg.pr.new/home/REDACTED/work/_temp/ghcca-node/node/bin/node node /home/REDACTED/work/_temp/ghcca-node/node/bin/pnpm install git rev-�� FETCH_HEAD(dns block)/home/REDACTED/work/_temp/ghcca-node/node/bin/node node /home/REDACTED/work/_temp/ghcca-node/node/bin/pnpm install --ignore-scripts --prefer-offline app.capabilities\|getCapabilities app/components/base/chat/embedded-chatbot/chat-wrapper.tsx app/components/base/chat/embedded-chatbot/header/__tests__/index.spec.tsx app/components/bbash app/components/b--norc app/components/b--noprofile app/components/base/chat/embedded-chatbot/inputs-form/__tests__/index.spec.tsx app/�� app/components/base/chat/embedded-chatbot/inputs-form/content.tsx app/components/base/chat/embedded-chatbot/inputs-form/index.tsx de/node/bin/bash app/components/bbash app/components/b--norc app/components/b--noprofile app/components/base/chat/embedded-chatbot/hooks.tsx(dns block)If you need me to access, download, or install something from one of these locations, you can either:
📍 Connect Copilot coding agent with Jira, Azure Boards or Linear to delegate work to Copilot in one click without leaving your project management tool.