Summary
When multiple users work through Levi (Paperclip) agent workspaces, all Git commits and merged PRs are attributed to a single Git identity (currently AnilChinchawale) instead of the actual user who triggered the work. This makes contributor tracking impossible and breaks GitHub's contributor insights.
Background & Motivation
- Levi runs agents in shared workspaces with a global
git config user.name/email set to one person
- When agents auto-commit and merge PRs, they use that global identity
- The
.mailmap file only maps the original Paperclip author (Dotta)
- No per-user or per-agent Git identity configuration exists in
companies/opea/agents/*/AGENTS.md or doc/DEVELOPING.md
- This affects all team members — everyone has provided their email IDs but they aren't being used
Proposed Solution
Environment Variable Injection (recommended)
- Add
gitName and gitEmail fields to user profiles (one-time setup per user)
- Inject
GIT_AUTHOR_NAME and GIT_AUTHOR_EMAIL into the agent workspace environment when it boots, based on the logged-in human user who triggered the agent
- Agent commit logic reads these env vars instead of global
user.name/user.email
Implementation Points
- Modify
packages/adapter-utils/src/server-utils.ts where PAPERCLIP_WORKSPACE_* env vars are constructed
- Add:
GIT_AUTHOR_NAME: user.gitName,
GIT_AUTHOR_EMAIL: user.gitEmail,
- Ensure agent Git operations (
git commit, git merge) respect these env vars
Alignment with ROADMAP.md
- Supports "Multiple Human Users" milestone (better multi-user support)
- Aligns with "Agent Reviews and Approvals" (proper audit trails need correct attribution)
Alternatives Considered
| Approach |
Pros |
Cons |
Per-company .mailmap |
Simple, no code changes |
Static, needs manual updates for every new user |
Manual git config per workspace |
Immediate fix |
Must run in every new repo/workspace, not scalable |
| Per-agent AGENTS.md identity |
Granular |
Overkill, most agents don't need unique identities |
Implementation Phases
- Phase 1: Add
gitName/gitEmail to user profile schema and UI
- Phase 2: Pass these values through workspace boot env vars
- Phase 3: Update agent Git commit/merge logic to prefer env vars over global config
- Phase 4: Backfill existing users, add to onboarding flow
Acceptance Criteria
Summary
When multiple users work through Levi (Paperclip) agent workspaces, all Git commits and merged PRs are attributed to a single Git identity (currently AnilChinchawale) instead of the actual user who triggered the work. This makes contributor tracking impossible and breaks GitHub's contributor insights.
Background & Motivation
git config user.name/emailset to one person.mailmapfile only maps the original Paperclip author (Dotta)companies/opea/agents/*/AGENTS.mdordoc/DEVELOPING.mdProposed Solution
Environment Variable Injection (recommended)
gitNameandgitEmailfields to user profiles (one-time setup per user)GIT_AUTHOR_NAMEandGIT_AUTHOR_EMAILinto the agent workspace environment when it boots, based on the logged-in human user who triggered the agentuser.name/user.emailImplementation Points
packages/adapter-utils/src/server-utils.tswherePAPERCLIP_WORKSPACE_*env vars are constructedgit commit,git merge) respect these env varsAlignment with ROADMAP.md
Alternatives Considered
.mailmapgit configper workspaceImplementation Phases
gitName/gitEmailto user profile schema and UIAcceptance Criteria
git configrequired per workspace