A self-improving RLM agent for coding workflows and long-running autonomous tasks.
Rust
remove the linear ticket requirement for pull requests (#2255)
kt46c60b750092
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.mdindex 424a6ad000..5788969c58 100644--- a/.github/PULL_REQUEST_TEMPLATE.md+++ b/.github/PULL_REQUEST_TEMPLATE.md@@ -6,11 +6,7 @@ https://github.com/PrimeIntellect-ai/prime-agent/discussions## Context-<!-- Link the accepted Issue or Discussion and explain why this change is needed.-Link a Prime Agent Linear ticket.-Engineering issues should use the Engineering (ENG) team and the Prime Agent V1 board.-Capabilities and research issues should use the Research (RES) team and the Prime Agent: Long-Horizon board.-If this change has no ticket, add `No-Ticket: <short reason>` below. -->+<!-- Link the accepted Issue or Discussion and explain why this change is needed. -->## Changesdiff --git a/.github/workflows/linear-ticket.yml b/.github/workflows/linear-ticket.ymldeleted file mode 100644index 0346efbf42..0000000000--- a/.github/workflows/linear-ticket.yml+++ /dev/null@@ -1,43 +0,0 @@-name: Linear ticket--on:- pull_request:- types: [opened, edited, reopened, synchronize]- branches: [main]--permissions:- pull-requests: read--jobs:- linear-ticket:- name: Check Linear ticket link- runs-on: ubuntu-latest- if: github.event.pull_request.user.type != 'Bot'- steps:- - name: Require a Linear ticket reference or an explicit opt-out- uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1- with:- script: |- const pr = context.payload.pull_request;- const text = `${pr.title}\n${pr.body ?? ""}\n${pr.head.ref}`;- const ticket = /\b(?:eng|res)-\d+\b/i;- const optOut = /^\s*No-Ticket:\s*\S.*$/im;- if (ticket.test(text)) {- core.info("Linear ticket reference found.");- return;- }- const match = (pr.body ?? "").match(optOut);- if (match) {- core.info(`No-ticket opt-out present: ${match[0].trim()}`);- return;- }- core.setFailed(- [- "No Linear ticket is linked in this pull request.",- "Engineering issues should use the Engineering (ENG) team and the Prime Agent V1 board.",- "Capabilities and research issues should use the Research (RES) team and the Prime Agent: Long-Horizon board.",- "Add the ticket ID (e.g. ENG-1234 or RES-1234) or a linear.app issue link to the PR title or description,",- "or use a branch named after the ticket (e.g. eng-1234 or res-1234).",- 'If this change genuinely has no ticket, add a line to the PR description: "No-Ticket: <short reason>".',- ].join(" "),- );diff --git a/package.json b/package.jsonindex 5f7efd314b..26995da820 100644--- a/package.json+++ b/package.json@@ -14,8 +14,7 @@"build": "cd packages/tui && npm run build && cd ../ai && npm run build && cd ../agent && npm run build && cd ../coding-agent && npm run build","dev": "concurrently --names \"ai,agent,coding-agent,tui\" --prefix-colors \"cyan,yellow,red,magenta\" \"cd packages/ai && npm run dev\" \"cd packages/agent && npm run dev\" \"cd packages/coding-agent && npm run dev\" \"cd packages/tui && npm run dev\"","dev:tsc": "cd packages/ai && npm run dev:tsc",- "check": "biome check --write --error-on-warnings . && tsgo --noEmit && npm run check:linear-ticket && npm run check:installer && npm run check:browser-smoke",- "check:linear-ticket": "node scripts/check-linear-ticket.mjs",+ "check": "biome check --write --error-on-warnings . && tsgo --noEmit && npm run check:installer && npm run check:browser-smoke","check:installer": "node scripts/check-installer.mjs","check:browser-smoke": "node scripts/check-browser-smoke.mjs","profile:tui": "node scripts/profile-coding-agent-node.mjs --mode tui",diff --git a/scripts/check-linear-ticket.mjs b/scripts/check-linear-ticket.mjsdeleted file mode 100644index 3bb8529301..0000000000--- a/scripts/check-linear-ticket.mjs+++ /dev/null@@ -1,77 +0,0 @@-#!/usr/bin/env node-import assert from "node:assert/strict";-import { readFileSync } from "node:fs";-import { compileFunction } from "node:vm";--const workflow = readFileSync(new URL("../.github/workflows/linear-ticket.yml", import.meta.url), "utf8");-const script = workflow.split(" script: |\n")[1];-assert.ok(script, "Missing inline Linear ticket validator");-const validate = compileFunction(script.replace(/^ {12}/gm, ""), ["context", "core"]);--function run(pr) {- const messages = [];- const failures = [];- validate(- { payload: { pull_request: pr } },- { info: (message) => messages.push(message), setFailed: (message) => failures.push(message) },- );- return { messages, failures };-}--const valid = [- "ENG-6006",- "res-1234",- "fix/eng-6006-bedrock-provider",- "https://linear.app/primeintellect/issue/ENG-6006/bedrock-requests-fail-because-the-published-cli-is-missing-its",- "[Research](https://linear.app/primeintellect/issue/RES-1234/research)",- "https://linear.app/team/issue/ENG-123",- "https://linear.app/team/issue/res-123?view=details#comment",-];-const invalid = [- "",- "Fix Bedrock provider loading",- "ENG-",- "ENG-123not-a-ticket",- "RES-123suffix",- "ENG-123_suffix",- "SOMETHING-ENG-",- "NOTENG-123",- "https://linear.app/team/issue/ENG-123not-a-ticket",- "https://linear.app/team/issue/RES-123suffix",- "https://linear.app/team/issue/ENG-123_suffix",- "https://linear.app/team/issue/ENG-no-number",- "https://linear.app/team/issue/OTHER-123",-];-let cases = 0;-for (const field of ["title", "body", "branch"]) {- for (const [references, expected] of [[valid, true], [invalid, false]]) {- for (const reference of references) {- const pr = { title: "Fix provider loading", body: "Validation details", head: { ref: "fix/provider" } };- if (field === "branch") pr.head.ref = reference;- else pr[field] = reference;- const result = run(pr);- assert.equal(result.failures.length, expected ? 0 : 1, `${field}: ${JSON.stringify(reference)}`);- assert.deepEqual(result.messages, expected ? ["Linear ticket reference found."] : []);- cases++;- }- }-}--for (const body of [undefined, "No-Ticket:", "No-Ticket: ", "No-Ticket:\n"]) {- assert.equal(run({ title: "Fix provider", body, head: { ref: "fix/provider" } }).failures.length, 1);- cases++;-}-const optOut = run({ title: "Update tooling", body: "No-Ticket: internal maintenance", head: { ref: "chore/tooling" } });-assert.deepEqual(optOut.failures, []);-assert.deepEqual(optOut.messages, ["No-ticket opt-out present: No-Ticket: internal maintenance"]);-cases++;--if (process.argv[2]) {- const pr = JSON.parse(readFileSync(process.argv[2], "utf8"));- assert.deepEqual(run({ title: pr.title, body: pr.body, head: { ref: pr.headRefName } }), {- messages: ["Linear ticket reference found."],- failures: [],- });- cases++;-}-console.log(`Linear ticket check passed (${cases} cases).`);