Audit merged PRs against Jira tickets using a LangGraph agent and MCP tools
Project description
MergeScope
Audits merged PRs against Jira tickets. Extracts Jira IDs from PR titles, descriptions, branch names, and commit messages, then validates each ticket's fixVersion against your expected release.
Powered by a LangGraph agent that talks to GitHub and Jira through MCP servers. Works standalone or with Amazon Q.
Install
uvx mergescope --help
Or permanently:
uv tool install mergescope
Usage
mergescope \
-f 2026-03-01 \
-t 2026-03-31 \
-v "1.2.0" \
-r company/backend
| Flag | Description |
|---|---|
-f, --from-date |
Start date (YYYY-MM-DD) |
-t, --to-date |
End date (YYYY-MM-DD) |
-v, --fix-version |
Expected Jira fixVersion |
-r, --repo |
GitHub repo (owner/repo) |
-c, --config |
Config file (default: mergescope.yaml) |
--mcp-config |
Amazon Q MCP config path |
--llm-provider |
anthropic, bedrock, copilot, or local |
--llm-model |
Model ID |
--llm-base-url |
API base URL (copilot/local) |
--language |
Response language (e.g. Spanish) |
--verbose |
Debug logging |
Multilingual prompts
Set a custom prompt in any language via mergescope.yaml:
language: "es"
response_language: "Spanish"
prompt_template: |
Necesito auditar tickets mergeados entre {from_date} y {to_date}.
La fixVersion esperada es {fix_version}.
Extrae los IDs de JIRA desde los merge commits del repositorio {repo}
y valida su fixVersion.
Configuration
Add a mergescope.yaml in your project root:
repo: "nice/java-project"
jira_project_prefix: "PROJ"
jira_base_url: "https://company.jira.com"
llm:
provider: "anthropic" # anthropic, bedrock, copilot, local
model: "claude-sonnet-4-6-20250620"
mcp:
servers:
github:
name: "github-mcp-server"
jira:
name: "atlassian-mcp-server"
LLM providers
| Provider | Model example | Notes |
|---|---|---|
anthropic |
claude-sonnet-4-6-20250620 |
Uses ANTHROPIC_API_KEY |
bedrock |
us.anthropic.claude-sonnet-4-20250514-v1:0 |
Uses AWS credentials |
copilot |
claude-sonnet-4 |
Set base_url to Copilot endpoint |
local |
qwen3-8b |
LM Studio, Ollama, or any OpenAI-compatible server |
MCP servers
Two modes — pick what fits your setup:
With Amazon Q (default): just set server names. MergeScope finds them in ~/.aws/amazonq/mcp.json or .amazonq/mcp.json.
Standalone (no Amazon Q): define command, args, and env directly:
mcp:
servers:
github:
name: "github-mcp-server"
command: "npx"
args: ["-y", "@anthropic/github-mcp-server"]
env:
GITHUB_TOKEN: "ghp_..."
jira:
name: "atlassian-mcp-server"
command: "npx"
args: ["-y", "@anthropic/atlassian-mcp-server"]
env:
JIRA_API_TOKEN: "..."
JIRA_URL: "https://company.jira.com"
You can mix both — some servers inline, others from Amazon Q.
Environment variables
MERGESCOPE_REPO, MERGESCOPE_LLM_PROVIDER, MERGESCOPE_LLM_MODEL, MERGESCOPE_LLM_BASE_URL, MERGESCOPE_LLM_API_KEY, MERGESCOPE_JIRA_BASE_URL, MERGESCOPE_LANGUAGE
Requirements
- Python 3.11+
- GitHub and Jira MCP servers (standalone or via Amazon Q)
- An LLM: Anthropic API key, AWS credentials, GitHub Copilot, or a local server
Development
git clone https://github.com/martin5211/MergeScope.git
cd MergeScope
uv venv && uv pip install -e .
pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mergescope-0.1.0.tar.gz.
File metadata
- Download URL: mergescope-0.1.0.tar.gz
- Upload date:
- Size: 13.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2bdb09dca44abd89f18ba6ec61b767fd9d9967ecee03e3ed1b8bc262653a2da2
|
|
| MD5 |
3e902eebd60a6dac0a27ef6623be6c30
|
|
| BLAKE2b-256 |
18e02d83639afb5b6b87b9c1f8a269555f4e99dd4c51ae84626007c43fadf46e
|
Provenance
The following attestation bundles were made for mergescope-0.1.0.tar.gz:
Publisher:
publish.yml on martin5211/MergeScope
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mergescope-0.1.0.tar.gz -
Subject digest:
2bdb09dca44abd89f18ba6ec61b767fd9d9967ecee03e3ed1b8bc262653a2da2 - Sigstore transparency entry: 1168351007
- Sigstore integration time:
-
Permalink:
martin5211/MergeScope@785eea715dcb61155dba1c8e19fe45996035a8fd -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/martin5211
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@785eea715dcb61155dba1c8e19fe45996035a8fd -
Trigger Event:
release
-
Statement type:
File details
Details for the file mergescope-0.1.0-py3-none-any.whl.
File metadata
- Download URL: mergescope-0.1.0-py3-none-any.whl
- Upload date:
- Size: 13.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
373dc78f90068d153a33dd0224974908db64be36608618b58cec17625e144412
|
|
| MD5 |
03900f86eb0182722af74462c7db379f
|
|
| BLAKE2b-256 |
5e1d8534d743d5ce6e6749048533a16ce28b497f6ea0f1a5ff64086e6f7f8dfd
|
Provenance
The following attestation bundles were made for mergescope-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on martin5211/MergeScope
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mergescope-0.1.0-py3-none-any.whl -
Subject digest:
373dc78f90068d153a33dd0224974908db64be36608618b58cec17625e144412 - Sigstore transparency entry: 1168351175
- Sigstore integration time:
-
Permalink:
martin5211/MergeScope@785eea715dcb61155dba1c8e19fe45996035a8fd -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/martin5211
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@785eea715dcb61155dba1c8e19fe45996035a8fd -
Trigger Event:
release
-
Statement type: