Project documentation

Run the classifier locally.

Bring a standards file and a Jira export. The agent applies the policy, classifies each issue, and writes both structured results and an explanation report.

REPO

This repository is a simplified proof of concept. Production use should be adapted to the organization’s policies, review controls, and data environment.

Production evidence

A client tested the approach in an Apptio Targetprocess production environment and deployed the implementation with Kiro.

Requirements

The current prototype runs against a local Ollama model. You’ll need:

  • Python 3.10 or newer
  • Ollama running locally
  • The qwen2.5:32b model
  • Python packages ollama and pandas

Qwen 2.5 32B is a large local model. Make sure the machine has enough memory for your Ollama configuration.

Install the local dependencies

Pull the model, then install the two Python packages used by the script.

$ ollama pull qwen2.5:32b
$ pip install ollama pandas

Describe your classification standards

Edit work-categories.csv. Each row gives the agent a category, its expected classification, applicable issue types, and the language that signals a match.

ColumnWhat it tells the agent
CategoryThe exact policy category name returned in results.
ClassificationWhether the category maps to CapEx or OpEx.
Jira Issue TypesThe comma-separated issue types eligible for the category.
DescriptionPlain-language scope and intent of the category.
Logic/RuleKeywords or signals used to match Jira work.

Add a Jira export

Place the items to classify in jira-items.csv. Issue Key and Summary are required; more context improves the quality of the reasoning.

ColumnStatusExample
Issue KeyRequiredPROJ-101
SummaryRequiredBuild new export API
Issue TypeRecommendedStory
DescriptionRecommendedBusiness and technical context

Run one classification pass

$ python capex-opex.py

The agent loads the standards, classifies Jira items in batches of five, merges the results, and generates a separate reasoning report.

  1. 1
    Context loading

    Formats and passes the company standards to the local model.

  2. 2
    Classification

    Returns CapEx or OpEx, confidence, reasoning, matched category, and matched rule.

  3. 3
    Reasoning report

    Rewrites each decision into a plain-language format for review.

Review both outputs

Files are timestamped and written to output/.

CSV

Classified items

<timestamp>_classified_items.csv

The original Jira data plus classification, confidence, short reasoning, matched category, and matched rule.

TXT

Reasoning report

<timestamp>_classification_reasoning.txt

A human-readable explanation and audit notes for every issue the model classified.

Start with the exceptions.

The script flags confidence below 70% in its terminal summary. Review those items first, then sample the high-confidence decisions for policy fit.

Configuration

Edit the CONFIG dictionary near the top of capex-opex.py to change the model, file paths, output directory, batch size, temperature, or context window.

CONFIG = {
    "model": "qwen2.5:32b",
    "standards_file": "work-categories.csv",
    "input_file": "jira-items.csv",
    "output_dir": "output",
    "batch_size": 5,
}

Know the boundaries of the POC

No accounting authority

The output is a recommendation for human review, not an accounting conclusion.

Prompt-based matching

Quality depends on the standards, Jira descriptions, and model behavior.

Conservative fallback

Uncertain classifications default to OpEx, and parse failures produce a 50% confidence fallback.

Local batch workflow

There is no Jira integration, web interface, approval flow, or persistent database in this prototype.

NEXT STEP Inspect the example input files
Browse the repository