Skip to content

Agent Run Commit Attribution - #3991

Open
michaeljguarino wants to merge 17 commits into
masterfrom
agent-run-commit-attribution
Open

Agent Run Commit Attribution#3991
michaeljguarino wants to merge 17 commits into
masterfrom
agent-run-commit-attribution

Conversation

@michaeljguarino

@michaeljguarino michaeljguarino commented Aug 10, 2026

Copy link
Copy Markdown
Member

Noticed the agent run initiator isn't getting marked as committer currently, this hopefully fixes.

Test Plan

Test environment: https://console.plrldemo.onplural.sh/cd/clusters/a1748282-ce8b-48ab-ae7e-326e74fce04e/services/f3f89a54-d1a7-4bc8-9152-daa07ede918d/components

Checklist

  • I have added a meaningful title and summary to convey the impact of this PR to a user.
  • If required, I have updated the Plural documentation accordingly.
  • I have added tests to cover my changes.
  • I have deployed the agent to a test environment and verified that it works as expected (required only when changing agent code).

Plural Flow: console

@michaeljguarino
michaeljguarino requested a review from a team August 10, 2026 19:56
@michaeljguarino michaeljguarino added the enhancement New feature or request label Aug 10, 2026
@soffi-ai

soffi-ai Bot commented Aug 10, 2026

Copy link
Copy Markdown

Soffi AI Summary

This PR bundles several largely independent improvements across the AI workbench, SCM integrations, and CI infrastructure under the headline fix of attributing the correct initiator as the Git committer on agent runs.

Agent Run Commit Attribution (primary fix): The agent run initiator was not being recorded as the Git committer when the agent pushed changes. This PR wires the actor/initiator identity through so that commits produced by AI agent runs are properly attributed.

AI Workbench enhancements:

  • Added project-level disablement of AI features, giving operators a kill-switch without touching individual resources.
  • Improved "babysit mode" behavior for more reliable agent supervision.
  • Added skill autodiscovery so the workbench can find and surface available tools automatically.
  • Implemented model/mode selection on reprompts, letting users switch LLM models or interaction modes mid-session.
  • Added workbench cost recommendations so users can see the cost impact of their AI sessions.
  • Added explanatory annotations to function-call and Kubernetes-update activities in the agent timeline.
  • Implemented an exec activity type and full frontend support for command execution in the workbench, including better responsiveness for pod exec interactions and proper handling of exec failures.

PubSub / polling improvements: Activity delivery and agent-run poll successes are now pushed via PubSub rather than polled, significantly improving UI responsiveness when agents are running.

SCM credentials refresh: Implemented automatic refresh of SCM (source control manager) credentials so long-lived agent sessions don't fail due to expired tokens.

Cloud connection management UI: Added in-UI management of cloud connections, allowing operators to configure and update cloud provider connections without leaving the Console.

CI infrastructure — revert Blacksmith CI migration: All GitHub Actions workflows that had been migrated to Blacksmith-hosted runners (blacksmith-*vcpu-ubuntu-* runners and useblacksmith/* actions) are reverted back to standard ubuntu-latest runners with docker/setup-buildx-action and docker/build-push-action, using GitHub Actions cache (type=gha) instead of Blacksmith's build cache. This affects the deployment operator harness (base, terraform, terragrunt, pulumi, ansible), cloud-query, kubernetes-agent, agentk, controller, datastore, ai-proxy, and deployment operator CD/CI workflows.

Commits

Commit Summary
132b9de Fix agent run commit attribution: wire the run initiator's identity through as the Git committer so that commits pushed by AI agent runs are properly attributed to the correct user.
2801cce Add project-level disablement of AI features, giving operators a coarse kill-switch to turn off AI capabilities for an entire project without modifying individual resources.
38613cc Fix a database migration error introduced alongside the AI disablement feature.
4981dbb Add explanatory annotations to function-call and Kubernetes-update activity entries in the agent run timeline for better observability.
5f8a951 Enable model and mode updates when the agent is reprompted, so users can switch LLM models or interaction modes mid-session.
8c1cbd1 Implement automatic SCM credential refresh so long-lived agent sessions do not fail due to expired source control tokens.
3c903aa Expose model/mode selection in the reprompt UI so users can change the active LLM or interaction mode directly from the frontend.
437d4d3 Add in-UI cloud connection management, allowing operators to configure and update cloud provider connections without leaving the Console.
0270481 Implement the 'exec' activity type in the agent run model to represent command execution steps in the workbench timeline.
1c09f4b Deliver activity events and agent-run poll successes via PubSub instead of polling, significantly improving UI responsiveness during active agent runs.
65eaada Add frontend support for displaying and interacting with command execution (exec) activities in the workbench UI.
b8984aa Improve pod exec responsiveness in the workbench terminal integration.
d6d2f6f Add skill autodiscovery so the workbench can automatically surface available tools and capabilities to the agent.
6f98105 Revert the Blacksmith CI migration: replace all Blacksmith-hosted runners and build actions with standard ubuntu-latest runners, docker/setup-buildx-action, and GitHub Actions cache across all affected workflows.
de0240a Improve 'babysit mode' supervision behavior for more reliable agent oversight and intervention.
e395845 Add workbench cost recommendations so users can see the cost impact of their AI agent sessions.
02c8a53 Properly surface and handle exec failures in the workbench so errors during command execution are reported correctly rather than silently swallowed.

Deploy in Soffi


Updated: 2026-08-14 02:28 UTC

@greptile-apps

greptile-apps Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR propagates an agent run's initiating user into the harness and uses that identity for repository-local Git commit attribution, while retaining the existing service-account and SCM fallbacks.

  • Adds the initiating user to the harness AgentRun representation and fragment mapping.
  • Resolves commit identity before handling either existing or newly cloned repositories.
  • Adds unit coverage for user propagation and identity fallback behavior.

Confidence Score: 5/5

The PR appears safe to merge, with no concrete regressions identified in the commit-attribution flow.

The AgentRun query already selects the initiating user, the mapping handles a nullable user safely, and both repository setup paths receive an identity while preserving established fallbacks.

Important Files Changed

Filename Overview
go/deployment-operator/pkg/agentrun-harness/agentrun/v1/types.go Adds a nullable initiating-user representation and safely maps it from the existing GraphQL fragment.
go/deployment-operator/pkg/agentrun-harness/agentrun/v1/types_test.go Verifies that the initiating user's name and email are copied into the harness model.
go/deployment-operator/pkg/agentrun-harness/environment/environment.go Centralizes Git identity resolution and applies it consistently to existing and newly cloned repositories.
go/deployment-operator/pkg/agentrun-harness/environment/environment_test.go Covers preference for the initiating user and fallback to SCM credentials and the default email.

Reviews (1): Last reviewed commit: "Agent Run Commit Attribution" | Re-trigger Greptile

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 4f24efb to 8555560 Compare August 10, 2026 20:54
@blacksmith-sh

This comment has been minimized.

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 8555560 to 3c8b0c8 Compare August 10, 2026 21:07
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment GitOps PR: https://github.com/pluralsh/plrl-up-demos/pull/2572

Promotes the console image to sha-a449881, built from source head a44988186549da6c2fe2aac6673c5a868b504b30.

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from e966823 to 6b5a35e Compare August 11, 2026 13:53
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment PR created: https://github.com/pluralsh/plrl-up-demos/pull/2573 — pins the demo console image to sha-6b5a35e and is annotated with Plural Service: mgmt/apps.

@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Requested GitOps deployment PR created: https://github.com/pluralsh/plrl-up-demos/pull/2574

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 4b954a4 to db4e98c Compare August 11, 2026 16:09
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Created the GitOps deployment PR for this request: https://github.com/pluralsh/plrl-up-demos/pull/2575 (console image tag: sha-db4e98c).

Triggered by: #3991 (comment)

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch 2 times, most recently from 19b4e24 to 453e11f Compare August 11, 2026 18:16
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment GitOps PR has been created: https://github.com/pluralsh/plrl-up-demos/pull/2578

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 453e11f to d2f2b7d Compare August 11, 2026 18:59
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from d2f2b7d to b4ba938 Compare August 11, 2026 19:04
@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment PR: https://github.com/pluralsh/plrl-up-demos/pull/2579

This deploys sha-d2f2b7d from commit d2f2b7da4e86512df72caf1e79a8dcb390c4f29f; reconciliation is associated with mgmt/apps.

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch 2 times, most recently from ff3c0b6 to 1639400 Compare August 11, 2026 20:00
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment GitOps PR: https://github.com/pluralsh/plrl-up-demos/pull/2580

Pins the demo console deployment to sha-1639400.

Triggered by: #3991 (comment)

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 97a2054 to d6d2f6f Compare August 13, 2026 12:59
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment GitOps PR: https://github.com/pluralsh/plrl-up-demos/pull/2593 — pins the demo console image to sha-d6d2f6f.

Restore GitHub-hosted runners and Docker build actions after Blacksmith introduced compatibility issues.
@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from c6ba0a1 to de0240a Compare August 13, 2026 16:00
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment GitOps PR has been created: https://github.com/pluralsh/plrl-up-demos/pull/2599

Image tag: sha-de0240a
Annotation: Plural Service: mgmt/apps

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 3a35e59 to 4401dc3 Compare August 13, 2026 16:43
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment PR created: https://github.com/pluralsh/plrl-up-demos/pull/2600 — pins console to sha-4401dc3 and annotates Plural Service: mgmt/apps.

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from 4401dc3 to b01a4b4 Compare August 13, 2026 17:15
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

Deployment PR: https://github.com/pluralsh/plrl-up-demos/pull/2601 — updates the demo console image to sha-b01a4b4. Attributed to Plural Service: mgmt/apps.

@michaeljguarino
michaeljguarino force-pushed the agent-run-commit-attribution branch from b01a4b4 to e395845 Compare August 13, 2026 17:39
@michaeljguarino

Copy link
Copy Markdown
Member Author

plural deploy this

@plural-copilot

Copy link
Copy Markdown
Contributor

The deployment GitOps PR has been created: https://github.com/pluralsh/plrl-up-demos/pull/2602

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

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants