René's URL Explorer Experiment


Title: feat(agent): make the conversational loop aware of its output schema by maxduu · Pull Request #2003 · UiPath/uipath-python · GitHub

Open Graph Title: feat(agent): make the conversational loop aware of its output schema by maxduu · Pull Request #2003 · UiPath/uipath-python

X Title: feat(agent): make the conversational loop aware of its output schema by maxduu · Pull Request #2003 · UiPath/uipath-python

Description: Why See UiPath/uipath-agents-python#900 for full context and testing. In summary: A conversational agent's structured output fields are filled by a separate LLM call after the loop ends. The loop itself never sees the output schema, so a builder who writes "set status to resolved in the output" in the system prompt gives the agent an instruction it cannot act on. The agent then either hunts for a tool that does not exist, or narrates the field values to the user. This is the uipath-python half: the prompt itself. Wiring lives in uipath-agents-python, and the extraction-call handling in uipath-langchain-python. What changes get_chat_system_prompt gains an optional output_schema parameter. When present, the schema's JSON is appended to the conversational system prompt under a STRUCTURED OUTPUT FOR THIS TURN section that tells the model three things: the fields are recorded after its turn by a separate step, there is no tool for them, and the reply the user reads should not mention them. Two supporting pieces: get_conversational_output_hint_section(output_schema) renders the section; it returns "" for None, so callers that pass nothing behave exactly as before. strip_conversational_output_hint_section(prompt) removes it again. The extraction call replays the exchange including the system message, where "you have no tool for these fields" would directly contradict the instruction telling the model to call set_conversational_output. Today a forced tool choice masks that contradiction; it would stop masking it as soon as models that reject forcing are downgraded to auto. The strip is schema-independent: its markers come from the section constants used to render it, so the two cannot drift. An earlier version re-rendered the section from the schema to find it, which silently did nothing whenever the caller had narrowed the schema differently. _GENERATE_OUTPUT_INSTRUCTION is also reworded to scope extraction to the current turn, so a value established in an earlier turn is not reported again when a flow loops back into the same agent. Testing 39 tests in test_conversational_prompts.py, covering the section's presence and absence, the schema JSON being injected verbatim, and strip ∘ assemble restoring the bare prompt byte-for-byte. End-to-end results are in the uipath-agents-python PR: 175 live runs across 7 authoring styles, 4 scenarios and 5 models. Summary — 8 replies leaked raw output JSON to the user without this section and 0 with it; 2 runs crashed inventing a tool and 0 with it; field accuracy unchanged.

Open Graph Description: Why See UiPath/uipath-agents-python#900 for full context and testing. In summary: A conversational agent's structured output fields are filled by a separate LLM call after the loop ends. The lo...

X Description: Why See UiPath/uipath-agents-python#900 for full context and testing. In summary: A conversational agent's structured output fields are filled by a separate LLM call after the loop ends. Th...

Opengraph URL: https://github.com/UiPath/uipath-python/pull/2003

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:0afdb900-4563-2ff4-b7a7-49639452e279
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idAC9A:168945:30AF84:415E67:6AFF6706
html-safe-noncef7e68488c7bec26f6ec7282a7a99bd99c7c4aa7ea9ff184bead8555e77ff7c19
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQzlBOjE2ODk0NTozMEFGODQ6NDE1RTY3OjZBRkY2NzA2IiwidmlzaXRvcl9pZCI6IjYzMzUxNDIyNzc4MDI0OTM1MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac8784c21b1ba3329f0251c620c20d375c73b1ac26ddc6b8d6f39b67152563518a
hovercard-subject-tagpull_request:5388518969
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/UiPath/uipath-python/pull/2003/files
twitter:imagehttps://avatars.githubusercontent.com/u/60411452?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/60411452?s=400&v=4
og:image:altWhy See UiPath/uipath-agents-python#900 for full context and testing. In summary: A conversational agent's structured output fields are filled by a separate LLM call after the loop ends. The lo...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None41b58589a1c4eda1e3c8904144a412b88ca4455f63ca2ad3629f2e9f3c3a1d12
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/UiPath/uipath-python git https://github.com/UiPath/uipath-python.git
octolytics-dimension-user_id375663
octolytics-dimension-user_loginUiPath
octolytics-dimension-repository_id925171912
octolytics-dimension-repository_nwoUiPath/uipath-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id925171912
octolytics-dimension-repository_network_root_nwoUiPath/uipath-python
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8968d6d6acc65d74e4df332d23932dd3fd0502a4
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/UiPath/uipath-python/pull/2003/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FUiPath%2Fuipath-python%2Fpull%2F2003%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FUiPath%2Fuipath-python%2Fpull%2F2003%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=UiPath%2Fuipath-python
Reloadhttps://github.com/UiPath/uipath-python/pull/2003/files
Reloadhttps://github.com/UiPath/uipath-python/pull/2003/files
Reloadhttps://github.com/UiPath/uipath-python/pull/2003/files
UiPathhttps://github.com/UiPath
uipath-pythonhttps://github.com/UiPath/uipath-python
Codehttps://github.com/UiPath/uipath-python
Issues81 (81)https://github.com/UiPath/uipath-python/issues
Pull requests144 (144)https://github.com/UiPath/uipath-python/pulls
Actionshttps://github.com/UiPath/uipath-python/actions
Projectshttps://github.com/UiPath/uipath-python/projects
Security and qualityhttps://github.com/UiPath/uipath-python/security
Insightshttps://github.com/UiPath/uipath-python/insights
Sign up for GitHub https://github.com/signup?return_to=%2FUiPath%2Fuipath-python%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2FUiPath%2Fuipath-python%2Fissues%2Fnew%2Fchoose
maxduuhttps://github.com/maxduu
mainhttps://github.com/UiPath/uipath-python/tree/main
feat-structured-output-in-prompthttps://github.com/UiPath/uipath-python/tree/feat-structured-output-in-prompt
Conversation 4 https://github.com/UiPath/uipath-python/pull/2003
Commits 8 https://github.com/UiPath/uipath-python/pull/2003/commits
Checks 186 https://github.com/UiPath/uipath-python/pull/2003/checks
Files changed 8 https://github.com/UiPath/uipath-python/pull/2003/files
feat(agent): make the conversational loop aware of its output schema https://github.com/UiPath/uipath-python/pull/2003/files#top
Show all changes 8 commits https://github.com/UiPath/uipath-python/pull/2003/files
db1ce98 feat: conversational prompts with trim method maxduu Nov 9, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/db1ce98cc4099d03b9daceda09d206b6cf5baba9
c1c2214 feat: improve prompt maxduu Nov 16, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/c1c2214923e3a8a00cfbc45a796232bd0fcb0d3f
5e3fb9c fix: rename and redo tests maxduu Nov 17, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/5e3fb9c96658d3b06b0253140b0a09260123ec04
4b6ed7f Merge remote-tracking branch 'origin/main' into feat-structured-outpu… maxduu Nov 18, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/4b6ed7f3a7f5f7ba12b08bb78a10ec5f776c186b
5f73620 style: unwrap the output-hint section prose and apply ruff format maxduu Nov 19, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/5f7362064523f46b4119cb0499da205d8f70954b
930650e fix: revert change maxduu Nov 19, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/930650ef598fe09e3576a3e385d715807b3b8b81
cf126a8 Merge branch 'main' into feat-structured-output-in-prompt maxduu Nov 19, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/cf126a81e664d8c02e8e995c7762da16ddb5bc8f
8bca118 fix: bump version maxduu Nov 19, 2026 https://github.com/UiPath/uipath-python/pull/2003/commits/8bca118d53293d7f6d5504342cba399b9428b1fb
Clear filters https://github.com/UiPath/uipath-python/pull/2003/files
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
pyproject.toml https://github.com/UiPath/uipath-python/pull/2003/files#diff-d0947f8bc36fec38f31b69e8edb3191c9dc2f98ce5b78f360e462e244debd0f1
uv.lock https://github.com/UiPath/uipath-python/pull/2003/files#diff-a9e439067864971ac1750b1580f8e96ef5ab47161e70b877b259ea09296adf40
uv.lock https://github.com/UiPath/uipath-python/pull/2003/files#diff-a4756e11295e823369b0e3afe9f31428205a44a5f7afbe4c545c96d65f0ae309
uv.lock https://github.com/UiPath/uipath-python/pull/2003/files#diff-7fcf7ce8f1139f8e5c41af5e3accc88f3aeb8ab8cc702c744bdd41ee029422eb
__init__.py https://github.com/UiPath/uipath-python/pull/2003/files#diff-ec05459a634f17ad5bb7892b1e16f51a68c35f35a3632dcc12f4905574c6201d
conversational_prompts.py https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
test_conversational_prompts.py https://github.com/UiPath/uipath-python/pull/2003/files#diff-8f5e7483f01e8321efa3787b6401a85a4456cfa96e7b466d0e7f9a104c99e65f
uv.lock https://github.com/UiPath/uipath-python/pull/2003/files#diff-efeee29d7c8092034bd6a65cd840950a53caecf98d99b7e5aaaf32a0aa3a05ec
packages/uipath/pyproject.tomlhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-d0947f8bc36fec38f31b69e8edb3191c9dc2f98ce5b78f360e462e244debd0f1
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/pyproject.toml
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/UiPath/uipath-python/pull/2003/{{ revealButtonHref }}
https://github.com/UiPath/uipath-python/pull/2003/files#diff-d0947f8bc36fec38f31b69e8edb3191c9dc2f98ce5b78f360e462e244debd0f1
packages/uipath/samples/attachment_evaluation_test/uv.lockhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-a9e439067864971ac1750b1580f8e96ef5ab47161e70b877b259ea09296adf40
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/samples/attachment_evaluation_test/uv.lock
Open in desktop https://desktop.github.com
how customized files appear on GitHubhttps://docs.github.com/github/administering-a-repository/customizing-how-changed-files-appear-on-github
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
packages/uipath/samples/csv_employee_generator/uv.lockhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-a4756e11295e823369b0e3afe9f31428205a44a5f7afbe4c545c96d65f0ae309
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/samples/csv_employee_generator/uv.lock
Open in desktop https://desktop.github.com
how customized files appear on GitHubhttps://docs.github.com/github/administering-a-repository/customizing-how-changed-files-appear-on-github
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
packages/uipath/samples/line_by_line_test/uv.lockhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-7fcf7ce8f1139f8e5c41af5e3accc88f3aeb8ab8cc702c744bdd41ee029422eb
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/samples/line_by_line_test/uv.lock
Open in desktop https://desktop.github.com
how customized files appear on GitHubhttps://docs.github.com/github/administering-a-repository/customizing-how-changed-files-appear-on-github
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
packages/uipath/src/uipath/agent/react/__init__.pyhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-ec05459a634f17ad5bb7892b1e16f51a68c35f35a3632dcc12f4905574c6201d
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/src/uipath/agent/react/__init__.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/UiPath/uipath-python/pull/2003/{{ revealButtonHref }}
https://github.com/UiPath/uipath-python/pull/2003/files#diff-ec05459a634f17ad5bb7892b1e16f51a68c35f35a3632dcc12f4905574c6201d
https://github.com/UiPath/uipath-python/pull/2003/files#diff-ec05459a634f17ad5bb7892b1e16f51a68c35f35a3632dcc12f4905574c6201d
packages/uipath/src/uipath/agent/react/conversational_prompts.pyhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/src/uipath/agent/react/conversational_prompts.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/UiPath/uipath-python/pull/2003/{{ revealButtonHref }}
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
https://github.com/UiPath/uipath-python/pull/2003/files#diff-359c2b7d8751bab1c2e5c2c0ac7e548fcb4dcbaf07afa4a84f192c2bdd83310c
packages/uipath/tests/agent/react/test_conversational_prompts.pyhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-8f5e7483f01e8321efa3787b6401a85a4456cfa96e7b466d0e7f9a104c99e65f
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/tests/agent/react/test_conversational_prompts.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/UiPath/uipath-python/pull/2003/{{ revealButtonHref }}
https://github.com/UiPath/uipath-python/pull/2003/files#diff-8f5e7483f01e8321efa3787b6401a85a4456cfa96e7b466d0e7f9a104c99e65f
https://github.com/UiPath/uipath-python/pull/2003/files#diff-8f5e7483f01e8321efa3787b6401a85a4456cfa96e7b466d0e7f9a104c99e65f
https://github.com/UiPath/uipath-python/pull/2003/files#diff-8f5e7483f01e8321efa3787b6401a85a4456cfa96e7b466d0e7f9a104c99e65f
packages/uipath/uv.lockhttps://github.com/UiPath/uipath-python/pull/2003/files#diff-efeee29d7c8092034bd6a65cd840950a53caecf98d99b7e5aaaf32a0aa3a05ec
View file https://github.com/UiPath/uipath-python/blob/8bca118d53293d7f6d5504342cba399b9428b1fb/packages/uipath/uv.lock
Open in desktop https://desktop.github.com
how customized files appear on GitHubhttps://docs.github.com/github/administering-a-repository/customizing-how-changed-files-appear-on-github
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
Please reload this pagehttps://github.com/UiPath/uipath-python/pull/2003/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.