Skip to content

Conversation

@Pavan-Microsoft
Copy link
Contributor

Purpose

This pull request updates the agent creation logic in conversation_agent_factory.py to clarify how prior conversation history and chart generation should be handled. The instructions for using context, generating charts, and returning JSON output have been made more explicit to improve data accuracy and user experience.

Key changes to agent behavior and response rules:

Conversation Context and Data Retrieval:

  • Updated guidance on using prior conversation history: it should only be used for context or vague follow-up requests, and only as a data source when all required values are explicitly listed and unambiguous; citation markers or sources from previous responses must never be reused. If a request specifies new metrics, entities, filters, or time ranges, or if the necessary data isn't in history, treat it as a new query and use tools/plugins to retrieve data.

Chart Generation and Numeric Data Handling:

  • Added strict requirements for chart generation: charts must not be generated without numeric data. If numeric data isn't available, tools/plugins must be used to retrieve it first; if still unavailable, return "Chart cannot be generated" instead of generating a chart.

JSON Output and Citations:

  • Clarified that raw JSON should only be returned when explicitly requested by the user for charts, graphs, or data visualizations; do not return JSON by default. For such requests, select the most appropriate chart type and leave the citations field empty.

Does this introduce a breaking change?

  • Yes
  • No

Golden Path Validation

  • I have tested the primary workflows (the "golden path") to ensure they function correctly without errors.

Deployment Validation

  • I have validated the deployment process successfully and all services are running as expected with this change.

@Avijit-Microsoft Avijit-Microsoft merged commit 1879be7 into dev Jan 16, 2026
4 checks passed
@Pavan-Microsoft Pavan-Microsoft deleted the pk-km-inconsistentresponce branch January 19, 2026 08:59
@github-actions
Copy link
Contributor

🎉 This PR is included in version 3.17.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants