TODO: will need revision
uv run python scripts/pipeline.py --jira-key RHAISTRAT-1084 --target-repo /Users/mmortari/git/openshift-ai-documentation./scripts/jira_exploration.py RHAISTRAT-1084
/jiracontext-populate
/prcontext-populate
./scripts/clone_code_repos.py
./scripts/doc_context_bootstrap.py
/docplan-create
/docwrite --target-repo /Users/mmortari/git/openshift-ai-documentation
/docreview
- process today "make me a demo"
- process today "based on a draft of the docs"
- hardcode based on (current) Red Hat openshift-ai-documentation repo
- ...even because, what if conventions will change in the future?
- Python 3.11+
- uv for dependency management
Install dependencies:
make installThe scripts require three environment variables for Jira connectivity. You can either export them in your shell or place them in a .env file at the repository root — the scripts will load it automatically if present (shell variables take precedence).
| Variable | Description | Example |
|---|---|---|
JIRA_SERVER |
Jira server base URL | https://issues.redhat.com |
JIRA_USER |
Jira username or email | [email protected] |
JIRA_TOKEN |
Jira API token (personal access token) | ABCdef123... |
Export directly:
export JIRA_SERVER="https://issues.redhat.com"
export JIRA_USER="[email protected]"
export JIRA_TOKEN="your-api-token"Or create a .env file in the repo root:
JIRA_SERVER=https://issues.redhat.com
[email protected]
JIRA_TOKEN=your-api-token
The .env file is gitignored. If any of the three variables is missing, the scripts exit with code 2.
Given a single issue key, explores the JIRA hierarchy to build a complete picture of a strategy and its implementation:
- Walks up the parent chain to find the owning RHAISTRAT
- Downloads the STRAT, its children, and filtered linked issues as individual markdown files
- Collects PR URLs from engineering tasks under Epic children, using optimized batch JQL calls to minimize API round-trips
- Writes a manifest (
artifacts/jiraexploration.md) with YAML frontmatter summarizing the hierarchy, PR URLs, and starting issue description
python scripts/jira_exploration.py RHOAIENG-53404
python scripts/jira_exploration.py RHAISTRAT-1084 --link-filter UXOutput: artifacts/jiraexploration/ with one {KEY}.md per issue and a manifest at artifacts/jiraexploration.md.
For architecture details and design rationale, see docs/jiraexploration.md.
Takes the raw exploration output and produces a curated, documentation-ready context set. A bootstrap script copies the starting issue and writes a manifest, then a Claude Code skill (/jiracontext-populate) uses an LLM subagent to evaluate each remaining issue file and copy in only those with meaningful documentation content. A link extraction script classifies all URLs into pull requests, code repositories (derived from PR URLs), and additional links.
# Full flow via the skill:
/jiracontext-populate
# Or run the scripts individually:
python scripts/jira_context_bootstrap.py
python scripts/jira_context_links.pyOutput: artifacts/jiracontext/ with curated issue files and a manifest at artifacts/jiracontext.md.
For design rationale, the copy-in vs prune decision, testing strategy (including LLM tests), and agentskills.io compliance details, see docs/jiracontext.md.
Takes the PR URLs from the jiracontext manifest, downloads patches and metadata via gh, strips noise (lock files, generated code, test hunks, whitespace-only changes), and uses LLM subagents to classify each PR by documentation relevance. A deterministic pre-classifier adds advisory hints based on title patterns and file analysis, and a post-hoc sanity check flags suspicious verdict distributions.
# Full flow via the skill:
/prcontext-populate
# Or run the scripts individually:
python scripts/pr_context_fetch.py
python scripts/pr_context_filter.py
python scripts/pr_context_preclassify.py
# ... (LLM summarization via skill) ...
python scripts/pr_context_verdict_check.pyOutput: artifacts/prcontext/ with filtered patches, per-PR summary files (with verdict reasoning), and a manifest at artifacts/prcontext.md.
For design rationale, the comparative evaluation prompt, pre-classification strategy, verdict sanity checks, and before/after results, see docs/prcontext.md.
Fetch a single issue as JSON:
python scripts/fetch_issue.py RHAISTRAT-123Fetch with markdown-converted description:
python scripts/fetch_issue.py RHAISTRAT-123 --markdownFetch an issue and all linked/child issues as markdown:
python scripts/fetch_issue.py RHAISTRAT-123 --fetch-all artifacts/jiraexplorationmake testTests use jira-emulator — no real Jira credentials needed.