Generate a management report from verified metrics
In this article (6 sections)
A management report should make the decision-relevant result easy to understand without weakening the underlying definitions. Generate narrative statements from verified metrics, include the reporting period and units, and avoid adding trends or explanations that the data do not support.
Automation is useful for consistent presentation. It should not turn a single period's total into an invented growth story.
Start from a verified artifact
The original automation lab produces three selected paid events totaling 3,500 paise for the configured week. Regional amounts are North 1,000, South 2,000 and Unknown 500.
Before generating a summary, verify the bundle's output hashes and reconcile the grouped amounts and counts. If verification fails, do not proceed to polished prose that makes the result appear authoritative.
The source contains only this defined reporting extract. It does not provide a comparable previous-period total, a target or evidence of what caused the amount.
Generate a restrained summary
import json
from decimal import Decimal
from pathlib import Path
from tempfile import TemporaryDirectory
from pipeline import run,verify_bundle
def inr(paise):
return f'INR {Decimal(paise)/Decimal(100):,.2f}'
config = json.loads(Path('report-config.json').read_text())
with TemporaryDirectory(prefix='management-report-example-') as temporary:
folder,created = run('events.csv','source-manifest.json',config,temporary)
verify_bundle(folder)
metrics = json.loads((folder/'metrics.json').read_text())
assert sum(group['amount_paise'] for group in metrics['by_region'].values())==metrics['amount_paise']
unknown = metrics['by_region']['Unknown']['amount_paise']
summary = (
f"Period: {metrics['period_start']} inclusive to {metrics['period_end']} exclusive.\n"
f"Selected paid events: {metrics['selected_events']}; amount: {inr(metrics['amount_paise'])}.\n"
f"Unassigned region amount: {inr(unknown)}.\n"
"No prior-period comparison or causal explanation is established by this extract.\n"
"Prepared for review; not distributed."
)
assert 'amount: INR 35.00' in summary
assert 'Unassigned region amount: INR 5.00' in summary
assert 'Selected paid events: 3' in summary
print(summary)Decimal formatting converts integer paise to a readable major-unit amount without introducing a floating-point display artifact. The report retains the original period boundary and states the missing comparison evidence.
Include the caveat that could change the decision
The unknown-region amount is ₹5, about 14.3% of the selected total. If the manager wants a regional allocation decision, that classification gap matters. Hiding it inside a grand total would make the report less useful even though the total remains correct.
The supplied source manifest also declares coverage rather than independently proving it. A management summary can link to the evidence record and state any unresolved source issue without dumping every technical detail into the main paragraph.
Choose caveats according to their effect on the decision. A readable report should surface material uncertainty, not overwhelm the reader with an undifferentiated list of every possible limitation.
Keep generated explanations tied to evidence
If a language model helps phrase the summary, give it the verified metrics and a constrained claim contract. Require it to distinguish supplied facts from proposed hypotheses, and validate every number against the deterministic source.
Do not ask it to explain why performance changed when no change or causal evidence has been established. A fluent explanation can be unsupported even when all displayed arithmetic is correct.
For this small report, a deterministic template is sufficient. Its behavior is easy to inspect and test. More flexible generation should be evaluated against a set of supported and unsupported cases before being used in a reporting workflow.
Separate presentation from approval
A well-formatted summary remains a draft until the relevant review step is complete. Preserve its source run identity and ensure any attachment comes from the same bundle.
For HTML or spreadsheet output, apply the appropriate escaping and cell-handling rules to untrusted text. The example prints only validated fixture values and fixed prose; it is not an HTML rendering or spreadsheet export implementation.
Exercise: add a prior-period dataset with the same eligibility and coverage contract. Calculate the absolute and percentage change deterministically, handle a zero baseline explicitly, and only then extend the summary with a comparison sentence.
NeuraPath's Data Analytics with Generative AI course connects verified calculations with business communication. A good management report is concise because its evidence is organized, not because important uncertainty has been removed.
Continue learning
This article is part of the Reliable reporting automation sequence. Use the neighbouring tasks when you need the prerequisite or the next application.
- Review the prerequisite or neighbouring task in Design a human approval step for automated report distribution.
- Continue with Archive report versions without overwriting the audit trail.
Pankit Kumar has 10 years in Data Science & AI, building and shipping production systems in regulated pharma and clinical environments. He is a freelance trainer at Boston Institute of Analytics, AnalytixLabs and Scaler, and has taught this material to thousands of working professionals.
This article is part of our Data Analytics with Generative AI programme — 3–4 months. The full analyst stack — Excel, SQL, Power BI and Python pipelines — then a generative-AI layer you can prove is right.
Explore Data Analytics with Generative AI