Mneme HQ checks AI-generated code changes against a team’s architectural decisions. For financial services teams, that covers security architecture decisions a rule can name: an exact line forbidden in payment code, an upper limit on a Python value such as a token lifetime, or a package name. In mneme-hq 0.11.0 those rules run through mneme check, the Claude Code hook and CI. Mneme does not certify compliance with any regulation, detect personal data by meaning, or enforce infrastructure or runtime policy. There is no financial services case study yet.
Architectural Security Governance · Financial services

Check Financial Services Security Decisions in Code AI Agents Write

Banks, insurers and payments teams already make security architecture decisions about their code. Three shipped Mneme rule kinds can check some of those decisions when a coding agent writes the change. Each has limits, listed below.

The Problem

An agent writes the line the security architecture forbids.

Security architects in financial services make decisions about how code handles data. Card numbers never reach a log line, and payment code calls the processor through one approved client library. Session tokens expire within an hour. Some of these decisions answer to frameworks such as the Payment Card Industry Data Security Standard (PCI DSS) or the EU Digital Operational Resilience Act (DORA). Mneme does not satisfy those frameworks.

A coding agent asked to fix a failing payment test works from the code and the prompt in front of it. It does not read the security architecture record. If it adds a debug line that logs the card number, only a reviewer who spots that line in the diff stops it.

What Applies

Three rule kinds apply, each with limits.

A security architect writes the decision as an Architecture Decision Record (ADR): a Markdown file with a Constraints section. mneme adr import compiles the constraints into rules stored in a memory file, .mneme/project_memory.json. mneme check then evaluates code changes against those rules in two places: the Claude Code hook, which runs before Claude Code’s Edit, Write and MultiEdit tools change a file, and CI. Each check returns PASS, WARN or FAIL. Strict mode exits non-zero on WARN or FAIL. Warn mode exits 0 on all three, and exits 2 only on an error or when a rule could not be evaluated (INCOMPLETE).

The examples below are illustrative. Tested runs with real output are on the Architectural Security Governance use case, with the full table of what Mneme checks and does not check. To try it yourself, start with the quickstart.

Rule kind (mneme-hq 0.11.0) Example decision Verdict and limits
FORBID_LITERAL with include_paths Forbid logger.info(card_number) in src/payments/**. FAIL, in the Claude Code hook and in CI. Exact, case-sensitive text, so a renamed variable or extra spaces pass. The rule skips files outside the listed paths.
FORBID_NUMERIC_ABOVE TOKEN_TTL_SECONDS must not exceed 3600 in Python files under src/**. FAIL, in CI only, on Python files checked with --source-file. The Claude Code hook does not evaluate it. In 0.11.0, once a numeric rule is in the memory file, every check that uses --input returns INCOMPLETE (exit 2), even in warn mode and for Python files.
FORBID_DEPENDENCY Flag requests where the team mandates an internal HTTP client for calls to the payment processor. WARN only, never FAIL, and no path scope. It matches any single word of the name anywhere in the file, so a comment that mentions requests also warns. A one-word name like this one is checked on every file.
Evidence

No case study yet.

There is no case study for financial services yet. This page describes what the shipped rule kinds can express. It does not report results from any bank, insurer or payments team. We will add one when a team agrees to publish theirs.

Scope

What Mneme does not do here.