Skip to content

A self-improving RLM agent for coding workflows and long-running autonomous tasks.

Rust

add trusted contribution process (#1340)

kt9f9501146e86
diff --git a/.github/DISCUSSION_TEMPLATE/bug-reports.yml b/.github/DISCUSSION_TEMPLATE/bug-reports.yml
new file mode 100644
index 0000000000..58560774e6
--- /dev/null
+++ b/.github/DISCUSSION_TEMPLATE/bug-reports.yml
@@ -0,0 +1,72 @@
+title: "[Bug] "
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thanks for reporting a problem. Search existing Discussions first and do not include API keys, tokens, private prompts, or other sensitive information.
+
+ If this may be a security vulnerability, stop and follow the private reporting instructions in SECURITY.md instead.
+ - type: dropdown
+ id: package
+ attributes:
+ label: Affected area
+ description: Which part of Prime Agent is affected?
+ multiple: true
+ options:
+ - Agent core
+ - AI providers and models
+ - Coding agent and CLI
+ - TUI
+ - Installation or updates
+ - Documentation
+ - Not sure
+ validations:
+ required: true
+ - type: textarea
+ id: description
+ attributes:
+ label: What happened?
+ description: Describe the problem and its impact.
+ validations:
+ required: true
+ - type: textarea
+ id: reproduce
+ attributes:
+ label: Steps to reproduce
+ description: Provide the smallest reliable sequence that reproduces the problem.
+ placeholder: |
+ 1. Run `prime-agent ...`
+ 2. ...
+ 3. Observe ...
+ validations:
+ required: true
+ - type: textarea
+ id: expected
+ attributes:
+ label: Expected behavior
+ description: What did you expect to happen instead?
+ validations:
+ required: true
+ - type: input
+ id: version
+ attributes:
+ label: Prime Agent version
+ description: Include the output of `prime-agent --version`, or the commit if running from source.
+ placeholder: "0.0.0 or commit SHA"
+ validations:
+ required: true
+ - type: input
+ id: environment
+ attributes:
+ label: Environment
+ description: Include your operating system, terminal, and any other relevant environment details.
+ placeholder: "macOS 15, Terminal.app"
+ validations:
+ required: true
+ - type: textarea
+ id: context
+ attributes:
+ label: Additional context
+ description: Add redacted logs, screenshots, or related Discussions if useful.
+ validations:
+ required: false
diff --git a/.github/DISCUSSION_TEMPLATE/feature-requests.yml b/.github/DISCUSSION_TEMPLATE/feature-requests.yml
new file mode 100644
index 0000000000..906d8ef22c
--- /dev/null
+++ b/.github/DISCUSSION_TEMPLATE/feature-requests.yml
@@ -0,0 +1,50 @@
+title: "[Feature] "
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Use this form to request a new capability or improvement. Search existing Discussions first so related requests stay together.
+ - type: dropdown
+ id: area
+ attributes:
+ label: Area
+ description: Which part of Prime Agent would this affect?
+ multiple: true
+ options:
+ - Agent core
+ - AI providers and models
+ - Coding agent and CLI
+ - TUI
+ - Installation or updates
+ - Documentation
+ - Not sure
+ validations:
+ required: true
+ - type: textarea
+ id: problem
+ attributes:
+ label: Problem
+ description: What are you trying to do, and what is difficult or impossible today?
+ validations:
+ required: true
+ - type: textarea
+ id: proposal
+ attributes:
+ label: Proposed direction
+ description: Describe the behavior or experience you would like to see.
+ validations:
+ required: true
+ - type: textarea
+ id: alternatives
+ attributes:
+ label: Alternatives considered
+ description: Share any workarounds or alternative approaches you have considered.
+ validations:
+ required: false
+ - type: textarea
+ id: context
+ attributes:
+ label: Additional context
+ description: Add examples, mockups, or related Discussions if useful.
+ validations:
+ required: false
diff --git a/.github/DISCUSSION_TEMPLATE/general.yml b/.github/DISCUSSION_TEMPLATE/general.yml
new file mode 100644
index 0000000000..111e8c8a73
--- /dev/null
+++ b/.github/DISCUSSION_TEMPLATE/general.yml
@@ -0,0 +1,44 @@
+title: "[General] "
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Start a general discussion or ask a focused question about Prime Agent. Search the documentation and existing Discussions first.
+ - type: dropdown
+ id: area
+ attributes:
+ label: Area
+ description: What is your discussion about?
+ multiple: true
+ options:
+ - Installation or updates
+ - Configuration and authentication
+ - Agent behavior
+ - AI providers and models
+ - Coding agent and CLI
+ - TUI
+ - Development
+ - Not sure
+ validations:
+ required: true
+ - type: textarea
+ id: topic
+ attributes:
+ label: Topic
+ description: What would you like to discuss, understand, or accomplish?
+ validations:
+ required: true
+ - type: textarea
+ id: attempted
+ attributes:
+ label: What have you tried or considered?
+ description: Include relevant commands, documentation, or approaches if useful.
+ validations:
+ required: false
+ - type: textarea
+ id: context
+ attributes:
+ label: Additional context
+ description: Add redacted logs, configuration details, or screenshots if useful.
+ validations:
+ required: false
diff --git a/.github/ISSUE_TEMPLATE/bug-report.yml b/.github/ISSUE_TEMPLATE/bug-report.yml
index 225f7580d8..f81d6d7ed2 100644
--- a/.github/ISSUE_TEMPLATE/bug-report.yml
+++ b/.github/ISSUE_TEMPLATE/bug-report.yml
@@ -1,22 +1,12 @@
---
-name: Bug report
-description: Report something that isn't working as expected
+name: Accepted bug (maintainers)
+description: Track a bug accepted from GitHub Discussions
labels: ["bug"]
body:
- - type: dropdown
- id: package
+ - type: markdown
attributes:
- label: Package
- multiple: true
- description: Which package(s) are affected? Select all that apply. A maintainer will apply the matching `pkg:*` labels.
- options:
- - agent
- - ai
- - coding-agent
- - tui
- - Not sure
- validations:
- required: true
+ value: |
+ Issues are the maintainer work queue. If a maintainer has not asked you to create this Issue, use the Bug report form in GitHub Discussions instead.
- type: textarea
id: description
attributes:
diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml
index 0086358db1..5c10c74f18 100644
--- a/.github/ISSUE_TEMPLATE/config.yml
+++ b/.github/ISSUE_TEMPLATE/config.yml
@@ -1 +1,11 @@
-blank_issues_enabled: true
+blank_issues_enabled: false
+contact_links:
+ - name: Start a general discussion
+ url: https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/general
+ about: Ask a question or discuss how Prime Agent works.
+ - name: Report a bug
+ url: https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/bug-reports
+ about: Report unexpected behavior through GitHub Discussions.
+ - name: Request a feature
+ url: https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/feature-requests
+ about: Request a new capability or improvement through GitHub Discussions.
diff --git a/.github/ISSUE_TEMPLATE/documentation-improvement.yml b/.github/ISSUE_TEMPLATE/documentation-improvement.yml
index c566ccd910..aaf42f9b7a 100644
--- a/.github/ISSUE_TEMPLATE/documentation-improvement.yml
+++ b/.github/ISSUE_TEMPLATE/documentation-improvement.yml
@@ -1,22 +1,12 @@
---
-name: Documentation improvement
-description: Report missing, incorrect, or unclear documentation
+name: Accepted documentation work (maintainers)
+description: Track documentation work accepted from GitHub Discussions
labels: ["documentation"]
body:
- - type: dropdown
- id: package
+ - type: markdown
attributes:
- label: Package
- multiple: true
- description: Which package(s) docs are affected? Select all that apply. A maintainer will apply the matching `pkg:*` labels.
- options:
- - agent
- - ai
- - coding-agent
- - tui
- - Not sure / general
- validations:
- required: true
+ value: |
+ Issues are the maintainer work queue. If a maintainer has not asked you to create this Issue, use GitHub Discussions instead.
- type: textarea
id: summary
attributes:
diff --git a/.github/ISSUE_TEMPLATE/feature-request.yml b/.github/ISSUE_TEMPLATE/feature-request.yml
index b9903467a7..36864cac3c 100644
--- a/.github/ISSUE_TEMPLATE/feature-request.yml
+++ b/.github/ISSUE_TEMPLATE/feature-request.yml
@@ -1,22 +1,12 @@
---
-name: Feature request
-description: Suggest a new feature or enhancement
+name: Accepted feature (maintainers)
+description: Track a feature accepted from GitHub Discussions
labels: ["enhancement"]
body:
- - type: dropdown
- id: package
+ - type: markdown
attributes:
- label: Package
- multiple: true
- description: Which package(s) would this feature affect? Select all that apply. A maintainer will apply the matching `pkg:*` labels.
- options:
- - agent
- - ai
- - coding-agent
- - tui
- - Not sure
- validations:
- required: true
+ value: |
+ Issues are the maintainer work queue. If a maintainer has not asked you to create this Issue, use the Feature request form in GitHub Discussions instead.
- type: textarea
id: problem
attributes:
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
new file mode 100644
index 0000000000..5788969c58
--- /dev/null
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -0,0 +1,17 @@
+<!--
+Pull requests are accepted from maintainers and vouched contributors only.
+If a maintainer has not invited this work, start with a GitHub Discussion:
+https://github.com/PrimeIntellect-ai/prime-agent/discussions
+-->
+
+## Context
+
+<!-- Link the accepted Issue or Discussion and explain why this change is needed. -->
+
+## Changes
+
+<!-- Summarize the focused behavior or documentation changes. -->
+
+## Validation
+
+<!-- List the checks and focused tests you ran. -->
diff --git a/.github/VOUCHED.td b/.github/VOUCHED.td
new file mode 100644
index 0000000000..946658cbb6
--- /dev/null
+++ b/.github/VOUCHED.td
@@ -0,0 +1,2 @@
+# Trusted external contributors, one GitHub username per line without @.
+# Maintainers, bots, and collaborators with write access are allowed automatically.
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index cfcc3fb74a..c8d79859b0 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -14,8 +14,26 @@ permissions:
contents: read
jobs:
+ trust:
+ name: Contributor trust
+ runs-on: ubuntu-latest
+ outputs:
+ allowed: ${{ github.event_name == 'push' || steps.vouch.outputs.vouched == 'true' }}
+ steps:
+ - name: Check pull request author
+ id: vouch
+ if: github.event_name == 'pull_request'
+ uses: mitchellh/vouch/action/check-user@d66fa29a64600490892131ad87597c30c91fcac4 # v1
+ with:
+ user: ${{ github.event.pull_request.user.login }}
+ allow-fail: true
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+
build-check:
name: Build and check
+ needs: trust
+ if: needs.trust.outputs.allowed == 'true'
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
@@ -47,6 +65,8 @@ jobs:
test:
name: Test (${{ matrix.name }})
+ needs: trust
+ if: needs.trust.outputs.allowed == 'true'
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
@@ -121,8 +141,8 @@ jobs:
build-check-test:
name: build-check-test
- if: always()
- needs: [build-check, test]
+ if: always() && needs.trust.outputs.allowed == 'true'
+ needs: [trust, build-check, test]
runs-on: ubuntu-latest
steps:
- name: Verify CI results
diff --git a/.github/workflows/contribution-gate.yml b/.github/workflows/contribution-gate.yml
new file mode 100644
index 0000000000..0661b446c9
--- /dev/null
+++ b/.github/workflows/contribution-gate.yml
@@ -0,0 +1,40 @@
+name: Contribution gate
+
+on:
+ issues:
+ types: [opened, reopened]
+ pull_request_target:
+ types: [opened, reopened, ready_for_review]
+
+permissions: {}
+
+jobs:
+ issue:
+ name: Check issue author
+ if: github.event_name == 'issues'
+ runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ issues: write
+ steps:
+ - uses: mitchellh/vouch/action/check-issue@d66fa29a64600490892131ad87597c30c91fcac4 # v1
+ with:
+ issue-number: ${{ github.event.issue.number }}
+ auto-close: true
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+
+ pull-request:
+ name: Check pull request author
+ if: github.event_name == 'pull_request_target'
+ runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ pull-requests: write
+ steps:
+ - uses: mitchellh/vouch/action/check-pr@d66fa29a64600490892131ad87597c30c91fcac4 # v1
+ with:
+ pr-number: ${{ github.event.pull_request.number }}
+ auto-close: true
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
new file mode 100644
index 0000000000..dc84807e67
--- /dev/null
+++ b/CONTRIBUTING.md
@@ -0,0 +1,43 @@
+# Contributing to Prime Agent
+
+Thanks for your interest in contributing to Prime Agent! Prime Agent is developed in public, and we welcome bug reports, feature requests, questions, and other feedback. To keep the project maintainable, public contributions begin in [GitHub Discussions](https://github.com/PrimeIntellect-ai/prime-agent/discussions).
+
+With the influx of agent-generated contributions, we do not review unsolicited pull requests or use public Issues as the initial intake queue. While we are open to contributions by agents, you are responsible for your code and must understand how it interacts with the entire project.
+
+## Start with a Discussion
+
+Choose the category that best matches what you want to share:
+
+- [General discussion or question](https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/general)
+- [Bug report](https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/bug-reports)
+- [Feature request](https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/feature-requests)
+
+Search existing Discussions before creating a new one. Include enough detail for someone else to understand and reproduce the problem, but do not share API keys, tokens, private prompts, or other sensitive information.
+
+For security vulnerabilities, follow [SECURITY.md](SECURITY.md) instead of posting publicly.
+
+## Issues
+
+GitHub Issues track work that maintainers have accepted and intend to investigate or implement. A maintainer may create an Issue from a Discussion when the scope is clear and the work fits the roadmap. An existing Issue does not automatically mean that an external pull request is wanted. Wait for a maintainer to invite implementation before starting substantial work.
+
+Issues opened by unapproved contributors are automatically closed and redirected to Discussions. To contribute, share interest in Discussions or corresponding issues, and maintainers can invite implementation for requested work.
+
+## Pull Requests and Trusted Contributors
+
+Prime Agent runs on user machines and can execute code with the user's permissions. We therefore limit pull requests to maintainers and trusted contributors who have been explicitly vouched for. Maintainers may vouch for someone after they have consistently demonstrated a useful understanding of the project through Discussions, issue investigation, testing, documentation, or other collaboration. There is no separate application process and no guarantee that participation will result in approval.
+
+Pull requests from unvouched contributors are automatically closed. If you are interested in contributing code, begin with a Discussion and work with the maintainers on the problem first.
+
+## Preparing an Approved Pull Request
+
+If a maintainer has invited a pull request:
+
+1. Keep the change focused on the accepted Issue or Discussion.
+2. Follow the repository's development rules and existing conventions.
+3. Add or update tests for behavioral changes.
+4. Run the relevant checks locally and describe the validation in the pull request.
+5. Avoid unrelated refactors or dependency changes.
+
+Development setup and commands are documented in the [development guide](packages/coding-agent/docs/development.md).
+
+Maintainers may close a pull request that changes scope, cannot be validated safely, or no longer fits the project roadmap.
diff --git a/README.md b/README.md
index 971a5d6ff6..b4fd502b06 100644
--- a/README.md
+++ b/README.md
@@ -99,6 +99,12 @@ Prime Agent is built for long-running work, especially for evaluations in resear
- [Architecture overview](packages/coding-agent/docs/architecture.md) — daemon, worker, kernel, and persistence boundaries
- [Development](packages/coding-agent/docs/development.md) — build and run from source
+## Contributing
+
+Start with a GitHub Discussion for [general questions](https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/general), [bug reports](https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/bug-reports), and [feature requests](https://github.com/PrimeIntellect-ai/prime-agent/discussions/categories/feature-requests). Maintainers promote accepted work into Issues, and pull requests are reviewed from maintainers and vouched contributors.
+
+Read the [contribution guidelines](CONTRIBUTING.md) for the full process. Report security vulnerabilities privately by following the [security policy](SECURITY.md).
+
## Acknowledgements
Our agent and TUI is built on top of [`pi`](https://github.com/earendil-works/pi). We thank the authors of `pi` for their valuable work.
diff --git a/SECURITY.md b/SECURITY.md
new file mode 100644
index 0000000000..13bf794d1c
--- /dev/null
+++ b/SECURITY.md
@@ -0,0 +1,25 @@
+# Security Policy
+
+## Reporting a Vulnerability
+
+Do not report security vulnerabilities through public Issues, Discussions, or pull requests.
+
+Send the report to [[email protected]](mailto:[email protected]). For encrypted communication and the current company-wide disclosure policy, see [primeintellect.ai/security](https://www.primeintellect.ai/security).
+
+Include the following when possible:
+
+- The affected version or commit
+- The affected component and environment
+- Reproduction steps or a minimal proof of concept
+- The expected and observed impact
+- Any known mitigations
+
+Do not include real API keys, tokens, personal data, or credentials in the report. Use redacted or disposable test values.
+
+## What to Expect
+
+Maintainers will assess the report, determine its scope, and coordinate remediation and disclosure when appropriate. Please allow time for investigation before publishing details that could put users at risk.
+
+Security fixes are generally prepared against the default branch and released on a schedule chosen by the maintainers. We do not guarantee fixes for older versions.
+
+For ordinary bugs, feature requests, and support questions, use [GitHub Discussions](https://github.com/PrimeIntellect-ai/prime-agent/discussions).