feat: add stable agentId to uipath.json for packaging and spans
Summary
uipath initmints a stableIdintouipath.json, preserved across re-init and backfilled for existing projectsuipath packsources the packageprojectIdfromuipath.jso#Id, falling back to the legacy.telemetry.jsonProjectKey- llmops spans now carry
agentIdread fromuipath.json(cached), falling back to thePROJECT_KEYenv var - span path caches only the
Idstring, not the wholeuipath.json(immutable value) - stop generating
telemetry.jsononuipath init
Why
a coded agent needs one stable identifier that survives authoring, packaging, and runtime so traces and deployed releases correlate back to the same agent. anchoring it in uipath.json also decouples the id from telemetry being enabled.
Development Packages
uipath
[project]
dependencies = [
# Exact version (copy-paste ready):
"uipath==2.10.83.dev1016956735",
# Any version from this PR (uncomment to use a range instead):
# "uipath>=2.10.83.dev1016950000,<2.10.83.dev1016960000",
]
[[tool.uv.index]]
name = "testpypi"
url = "https://test.pypi.org/simple/"
publish-url = "https://test.pypi.org/legacy/"
explicit = true
[tool.uv.sources]
uipath = { index = "testpypi" }
uipath-platform = { index = "testpypi" }
[tool.uv]
override-dependencies = ["uipath-platform==0.1.65.dev1016956735"]
uipath-platform
[project]
dependencies = [
# Exact version (copy-paste ready):
"uipath-platform==0.1.65.dev1016956737",
# Any version from this PR (uncomment to use a range instead):
# "uipath-platform>=0.1.65.dev1016950000,<0.1.65.dev1016960000",
]
[[tool.uv.index]]
name = "testpypi"
url = "https://test.pypi.org/simple/"
publish-url = "https://test.pypi.org/legacy/"
explicit = true
[tool.uv.sources]
uipath-platform = { index = "testpypi" }
But langgraph/llamaindex agents build their own operate.json in the plugin repos and won't source projectId from uipath.json#agentId
This is not true. All UiPath Coded Agents are using the same packager. No changes are needed in the integration repos.
Separately, on alignment with the vertical-solutions-check-agent-id.yml check
This is not a concern for the coded agents SDK. the changes are backwards compatible, meaning that existing IDs will still be honored. newly created agents will indeed drop telemetry.json file. Any consumer (like that gh action) need to be updated to reflect the new behaviour -> uipath.json as the source of truth.
Could we extend this to cover function project types as well?
agentIdisn't the right name for a coded function, could we detect the project type and usefunctionIdaccordingly, or pick a generic name that works for both?
If you ask me, everything that can run on the UiPath platform should have a unique GUID identifier that never changes. RPA, coded functions, coded agents, low code agents, etc.
ProjectId kind of already seems a generic candidate for that.. but agentId already got introduced as a special ID just for agents.
We either keep introducing special IDs such as functionId, or we try to limit the number of IDs we have and stick to a generic ProjectId or something similar
CC @JosephMar
We either keep introducing special IDs such as functionId, or we try to limit the number of IDs we have and stick to a generic ProjectId or something similar
Agreed. the problem is that we already have a ProjectKey (similar to project id, that is the release key from orchestrator). to be consistent with the agentId naming (which is already the established field for low code agents today) I would use functionId for functions. I will also consult with the team regarding this since it would be a spec decision
We either keep introducing special IDs such as functionId, or we try to limit the number of IDs we have and stick to a generic ProjectId or something similar
Agreed. the problem is that we already have a ProjectKey (similar to project id, that is the release key from orchestrator). to be consistent with the agentId naming (which is already the established field for low code agents today) I would use functionId for functions. I will also consult with the team regarding this since it would be a spec decision
IMO every product should define its own GUID (I imagine you'll need this exposed downstream at some point). For Agents we are exposing a concrete AgentIId which must be separate from ProjectId (because of flow) so the generic approach might not work well unless you also include a discriminator, but at that point having separate IDs is probably similar overhead
@jepadil23 FYI this is similar to what we are solving for Trace service ID hierarchy
Settled on uipath.json#Id for both agents and functions. Updated also the spec docs.
:rotating_light: Heads up: uipath-integrations cross-tests are FAILING :rotating_light:
Your changes may break one or more integrations in uipath-integrations-python:
uipath-openai-agentsuipath-google-adkuipath-agent-frameworkuipath-llamaindexuipath-pydantic-ai
:warning: These checks are NOT enforced by branch protection rules. Please review the failures before merging.
:mag: Inspect the failed run →
Quality Gate passed
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
95.8% Coverage on New Code
0.0% Duplication on New Code
:rotating_light: Heads up: uipath-langchain cross-tests are FAILING :rotating_light:
Your changes may break the uipath-langchain-python integration.
:warning: These checks are NOT enforced by branch protection rules. Please review the failures before merging.
:mag: Inspect the failed run →