flyleaf 0.5.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
flyleaf/waivers.py ADDED
@@ -0,0 +1,124 @@
1
+ # Copyright 2026 Krishna Dahale
2
+ # SPDX-License-Identifier: Apache-2.0
3
+ """Waivers that suppress a finding for a stated reason, until a stated date.
4
+
5
+ A waiver is a deliberate, written act. It needs a reason, a person, and an
6
+ expiry date. Silence is not a waiver, and nothing is suppressed forever.
7
+ """
8
+
9
+ import tomllib
10
+ from dataclasses import dataclass
11
+ from datetime import date
12
+ from pathlib import Path
13
+
14
+ WAIVER_FILE = Path(".flyleaf") / "waivers.toml"
15
+ EXPIRY_WARNING_DAYS = 14
16
+ REQUIRED_FIELDS = ("component", "reason", "approved_by", "expires")
17
+
18
+
19
+ @dataclass(frozen=True)
20
+ class Waiver:
21
+ component: str
22
+ change: str | None
23
+ reason: str
24
+ approved_by: str
25
+ expires: date
26
+
27
+ def covers(self, component_id: str, change: str) -> bool:
28
+ if self.component != component_id:
29
+ return False
30
+ return self.change is None or self.change == change
31
+
32
+ def days_left(self, today: date) -> int:
33
+ return (self.expires - today).days
34
+
35
+ def payload(self, today: date) -> dict:
36
+ return {
37
+ "component": self.component,
38
+ "change": self.change,
39
+ "reason": self.reason,
40
+ "approved_by": self.approved_by,
41
+ "expires": self.expires.isoformat(),
42
+ "days_left": self.days_left(today),
43
+ }
44
+
45
+
46
+ def load_waivers(repo: Path) -> tuple[list[Waiver], list[str]]:
47
+ """Read `.flyleaf/waivers.toml`. Return the valid waivers and any problems.
48
+
49
+ A malformed entry is reported and ignored. It never suppresses a finding.
50
+ """
51
+ path = repo / WAIVER_FILE
52
+ if not path.is_file():
53
+ return [], []
54
+ try:
55
+ data = tomllib.loads(path.read_text(encoding="utf-8"))
56
+ except (OSError, UnicodeError, tomllib.TOMLDecodeError) as exc:
57
+ return [], [f"Could not read {WAIVER_FILE.as_posix()}: {exc}"]
58
+
59
+ entries = data.get("waiver")
60
+ if entries is None:
61
+ return [], []
62
+ if not isinstance(entries, list):
63
+ return [], [f"{WAIVER_FILE.as_posix()}: waiver must be a list of tables."]
64
+
65
+ waivers: list[Waiver] = []
66
+ problems: list[str] = []
67
+ for index, entry in enumerate(entries, 1):
68
+ waiver, problem = _parse(entry, index)
69
+ if problem:
70
+ problems.append(problem)
71
+ if waiver:
72
+ waivers.append(waiver)
73
+ return waivers, problems
74
+
75
+
76
+ def _parse(entry, index: int) -> tuple[Waiver | None, str | None]:
77
+ label = f"{WAIVER_FILE.as_posix()} entry {index}"
78
+ if not isinstance(entry, dict):
79
+ return None, f"{label}: not a table."
80
+
81
+ missing = [field for field in REQUIRED_FIELDS if not entry.get(field)]
82
+ if missing:
83
+ return None, (
84
+ f"{label}: ignored because it is missing {', '.join(missing)}. "
85
+ "A waiver needs a component, a reason, an approver, and an expiry date."
86
+ )
87
+
88
+ expires = entry["expires"]
89
+ if isinstance(expires, date):
90
+ expiry = expires
91
+ else:
92
+ try:
93
+ expiry = date.fromisoformat(str(expires))
94
+ except ValueError:
95
+ return None, f"{label}: expires must be a date such as 2026-12-31."
96
+
97
+ change = entry.get("change")
98
+ if change in ("", "*", None):
99
+ change = None
100
+
101
+ return (
102
+ Waiver(
103
+ component=str(entry["component"]),
104
+ change=None if change is None else str(change),
105
+ reason=str(entry["reason"]),
106
+ approved_by=str(entry["approved_by"]),
107
+ expires=expiry,
108
+ ),
109
+ None,
110
+ )
111
+
112
+
113
+ def match(waivers: list[Waiver], component_id: str, change: str) -> Waiver | None:
114
+ """Return the covering waiver, expired or not.
115
+
116
+ A more specific waiver, one naming the change, wins over a blanket one.
117
+ """
118
+ best: Waiver | None = None
119
+ for waiver in waivers:
120
+ if not waiver.covers(component_id, change):
121
+ continue
122
+ if best is None or (best.change is None and waiver.change is not None):
123
+ best = waiver
124
+ return best
@@ -0,0 +1,438 @@
1
+ Metadata-Version: 2.4
2
+ Name: flyleaf
3
+ Version: 0.5.0
4
+ Summary: Local inventory of AI components in a repository. Not a legal risk classifier.
5
+ Keywords: eu-ai-act,inventory,model-card,cli
6
+ Author: Krishna Dahale
7
+ Author-email: Krishna Dahale <krishy.ai.d@gmail.com>
8
+ License-Expression: Apache-2.0
9
+ License-File: LICENSE
10
+ Classifier: Development Status :: 3 - Alpha
11
+ Classifier: Environment :: Console
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Intended Audience :: Legal Industry
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Topic :: Software Development :: Quality Assurance
19
+ Classifier: Topic :: Software Development :: Documentation
20
+ Requires-Dist: typer>=0.12
21
+ Requires-Python: >=3.11
22
+ Project-URL: Homepage, https://github.com/krishyaid-coder/flyleaf
23
+ Project-URL: Repository, https://github.com/krishyaid-coder/flyleaf
24
+ Project-URL: Issues, https://github.com/krishyaid-coder/flyleaf/issues
25
+ Description-Content-Type: text/markdown
26
+
27
+ # flyleaf
28
+
29
+ [![ci](https://github.com/krishyaid-coder/flyleaf/actions/workflows/ci.yml/badge.svg)](https://github.com/krishyaid-coder/flyleaf/actions/workflows/ci.yml)
30
+ [![pypi](https://img.shields.io/pypi/v/flyleaf)](https://pypi.org/project/flyleaf/)
31
+ [![python](https://img.shields.io/pypi/pyversions/flyleaf)](https://pypi.org/project/flyleaf/)
32
+ [![license](https://img.shields.io/badge/license-Apache--2.0-blue)](LICENSE)
33
+
34
+ <p align="center">
35
+ <img src="https://raw.githubusercontent.com/krishyaid-coder/flyleaf/main/flyleaf.png" alt="flyleaf" width="220">
36
+ </p>
37
+
38
+ flyleaf is a local documentation clerk for AI code. It inventories the AI libraries in a repository, cites the EU AI Act provisions a person should read, and reports when a model card is missing or has fallen behind the code.
39
+
40
+ A flyleaf is the blank page bound in front of a book, the page where you say what the book is. This tool prepares that page and keeps a record of when the book moves on.
41
+
42
+ Legal classification depends on the use case. The use case is not in the import. flyleaf prepares the inventory and the questions. A person decides what the law requires. This output is not legal advice.
43
+
44
+ <p align="center">
45
+ <img src="https://raw.githubusercontent.com/krishyaid-coder/flyleaf/main/demo.gif" alt="flyleaf finding documentation drift, waiving one finding, and reopening a lapsed waiver" width="820">
46
+ </p>
47
+
48
+ ## Architecture
49
+
50
+ Detection rules and the citation pack are separate. The scanner names what it found in the tree. The pack names the provision to read, the Official Journal text, and the date that text was current. Every report copies the pack version, so a later edit to the pack does not rewrite an older run.
51
+
52
+ ```mermaid
53
+ flowchart TD
54
+ repo[Repository]
55
+ rules[Detection rules]
56
+ pack[Citation pack]
57
+ declared[Declared systems]
58
+ scan[flyleaf scan]
59
+ inventory[Inventory]
60
+ brief[flyleaf brief]
61
+ card[flyleaf card]
62
+ cite[flyleaf cite]
63
+ person[Person decides]
64
+
65
+ repo --> scan
66
+ rules --> scan
67
+ pack --> scan
68
+ declared --> scan
69
+ scan --> inventory
70
+ repo --> brief
71
+ pack --> brief
72
+ inventory --> card
73
+ pack --> cite
74
+ inventory --> person
75
+ brief --> person
76
+ card --> person
77
+ cite --> person
78
+ ```
79
+
80
+ `brief` scans the same rules at two states and diffs the inventories. Line numbers can move without a finding. A finding appears when a component is added or removed, when the import or dependency text changes, or when the model card content changes. The base is a git ref, or the recorded baseline.
81
+
82
+ ```mermaid
83
+ flowchart LR
84
+ baseRef[Base git ref or baseline]
85
+ headRef[Head git ref or working tree]
86
+ scanBase[Scan base]
87
+ scanHead[Scan head]
88
+ diff[Diff inventories]
89
+ graded[Grade impact and severity]
90
+ waivers[Apply waivers]
91
+ rollup[Roll up declared systems]
92
+ memo[Brief with citations]
93
+
94
+ baseRef --> scanBase
95
+ headRef --> scanHead
96
+ scanBase --> diff
97
+ scanHead --> diff
98
+ diff --> graded --> waivers --> rollup --> memo
99
+ ```
100
+
101
+ Waivers are applied to components first, then to systems, so a waiver on one file shrinks a system finding rather than silencing it.
102
+
103
+ A waiver suppresses a finding for a stated reason, until a stated date. It is never silent and never permanent. An expired waiver puts the finding back in front of a person.
104
+
105
+ ```mermaid
106
+ flowchart LR
107
+ finding[Finding]
108
+ check{Covering waiver?}
109
+ valid{Still in date?}
110
+ active[Active finding]
111
+ waived[Waived and logged]
112
+ reopened[Reopened, waiver expired]
113
+
114
+ finding --> check
115
+ check -->|no| active
116
+ check -->|yes| valid
117
+ valid -->|yes| waived
118
+ valid -->|no| reopened
119
+ ```
120
+
121
+ The pack moves only when you publish a new version. A scan does not fetch the law.
122
+
123
+ ```mermaid
124
+ flowchart LR
125
+ official[Official Journal text]
126
+ edit[Edit the citation pack]
127
+ version[New pack version and changelog entry]
128
+ report[Reports record that version]
129
+
130
+ official --> edit --> version --> report
131
+ ```
132
+
133
+ ## What a component is
134
+
135
+ A component is one detected framework in one file: `app.py` importing `openai`, or `pyproject.toml` depending on `scikit-learn`. That is evidence. An AI system is a grouping a person makes from those components. flyleaf does not invent that grouping, and it does not assign a risk tier.
136
+
137
+ You can declare the grouping yourself. See Systems below. Once declared, a system is what the brief reports and what `card` scaffolds, so one system needs one card rather than one per file.
138
+
139
+ Status values on a finding are `missing` and `needs_review`. `missing` means a model card file was not found, or was removed. `needs_review` means a person should read the cited provision against the change. The tool does not declare that a law was breached.
140
+
141
+ ## Impact and severity
142
+
143
+ Every finding carries an impact and a severity.
144
+
145
+ `impact` is `runtime` when the detected code changed, and `documentation` when only the model card did. A new dependency behaves differently from a reworded card, so the two are not mixed.
146
+
147
+ `severity` is `high`, `medium`, or `low`. It ranks how much engineering attention a change deserves. It is not a legal risk tier and says nothing about whether an obligation applies.
148
+
149
+ | Change | Impact | Severity |
150
+ |---|---|---|
151
+ | `added` with no model card | runtime | high |
152
+ | `added` with a model card | runtime | medium |
153
+ | `removed` | runtime | medium |
154
+ | `evidence_changed` | runtime | high |
155
+ | `card_stale` | runtime | high |
156
+ | `evidence_and_card_changed` | runtime | medium |
157
+ | `card_removed` | documentation | high |
158
+ | `card_added` | documentation | low |
159
+ | `card_changed` | documentation | low |
160
+
161
+ A system finding takes the severity of its worst component, and its impact is `runtime` when any component inside it changed code.
162
+
163
+ ## Install
164
+
165
+ ```bash
166
+ uv tool install flyleaf
167
+ flyleaf --help
168
+ ```
169
+
170
+ `pipx install flyleaf` and `pip install flyleaf` work too. Python 3.11 or later. The only runtime dependency is typer.
171
+
172
+ To work on flyleaf itself:
173
+
174
+ ```bash
175
+ git clone https://github.com/krishyaid-coder/flyleaf
176
+ cd flyleaf
177
+ uv sync
178
+ uv run pytest
179
+ ```
180
+
181
+ ## Scan
182
+
183
+ ```bash
184
+ uv run flyleaf scan .
185
+ uv run flyleaf scan . --format markdown
186
+ uv run flyleaf scan . -o inventory.json
187
+ ```
188
+
189
+ `scan` exits 0 when it finishes, including when it finds AI libraries. Using PyTorch is not a failed build.
190
+
191
+ Python files and code cells in `.ipynb` notebooks are read with the standard-library AST. `requirements*.txt`, `pyproject.toml`, and `package.json` are read as dependency lists. A keyword that happens to match a package name is not treated as a dependency. JavaScript imports inside `.ts` and `.js` files are not parsed yet. Scoped packages such as `@anthropic-ai/sdk` are recognized when they appear in `package.json`.
192
+
193
+ A model card counts as present when `MODEL_CARD.md` (or `model_card.md` / `modelcard.md`, markdown or yaml) sits next to the file or at the repository root. A component in a declared system uses that system's card instead.
194
+
195
+ JSON is the default. Every inventory includes:
196
+
197
+ - `citation_pack.version` and `citation_pack.as_of`
198
+ - `citations`, the entries this report actually used, each with pinpoint, quote, note, CELEX, and source URL
199
+ - `components[]` with `path`, `framework`, `category`, `role_hint`, `system`, `evidence`, `review_hints`, `model_card_status`, and `documentation_citation_ids`
200
+ - `systems[]`, the groupings you declared, each with its owner, card status, and component ids
201
+ - a disclaimer
202
+ - `warnings` for files that could not be parsed
203
+
204
+ `role_hint` is one of `api_client`, `orchestration`, or `local_ml`. It tells you which definition to read. It is not a finding that you are a provider or a deployer.
205
+
206
+ ## Systems
207
+
208
+ One library used in three files is three components. Whether it is one system or three depends on who the output reaches and what for, and that is not in the import. flyleaf will not guess it, so you declare it in `.flyleaf/systems.toml`. Commit that file.
209
+
210
+ ```toml
211
+ [[system]]
212
+ name = "support-bot"
213
+ owner = "platform@example.com"
214
+ card = "docs/cards/support-bot.md"
215
+ includes = ["app/chat/*", "pyproject.toml"]
216
+
217
+ [[system]]
218
+ name = "ticket-summarizer"
219
+ owner = "support@example.com"
220
+ card = "docs/cards/ticket-summarizer.md"
221
+ includes = ["jobs/summarize.py"]
222
+ ```
223
+
224
+ `name` and `includes` are required. `card` and `owner` are optional. An entry missing a required field is ignored, reported as a warning, and its files fall back to standing alone.
225
+
226
+ An include is an exact path, a glob, or a directory prefix, all relative to the repository root and written with forward slashes. A `*` spans separators, so `app/*` claims everything beneath `app`. A file claimed by two systems goes to the first one declared, and the scan warns that it was contested. A system that claims no detected component also warns, because that usually means a pattern is wrong.
227
+
228
+ ```mermaid
229
+ flowchart LR
230
+ fileA[app/chat/bot.py]
231
+ fileB[pyproject.toml]
232
+ fileC[jobs/summarize.py]
233
+ compA[Component openai]
234
+ compB[Component openai]
235
+ compC[Component openai]
236
+ sysA[System support-bot]
237
+ sysC[System ticket-summarizer]
238
+ cardA[One card]
239
+ cardC[One card]
240
+
241
+ fileA --> compA --> sysA
242
+ fileB --> compB --> sysA
243
+ fileC --> compC --> sysC
244
+ sysA --> cardA
245
+ sysC --> cardC
246
+ ```
247
+
248
+ Declaring a system changes three things. The declared `card` becomes the card for every component in the system, so one file documents the whole thing. The brief reports one finding per system instead of one per file, listing the components inside it as evidence. `flyleaf card` writes one scaffold per system.
249
+
250
+ Components you do not claim are still reported individually. Nothing is hidden by leaving the file out.
251
+
252
+ ## Who owns a finding
253
+
254
+ A finding that names nobody is a finding nobody does. Every finding in a brief carries two names, and they answer different questions.
255
+
256
+ `owner` is the `owner` field of the declared system. It is accountable for the system whoever happened to type the change.
257
+
258
+ `author` is read from `git blame` on the evidence line that changed. It is whoever last touched that line, which is usually the person who can answer the question fastest.
259
+
260
+ ```mermaid
261
+ flowchart TD
262
+ finding[Finding]
263
+ blame{Author from git blame?}
264
+ bot{Is it a bot?}
265
+ owner{Declared owner?}
266
+ askAuthor[Ask the author]
267
+ askOwner[Ask the owner]
268
+ unassigned[Unassigned, and says so]
269
+
270
+ finding --> blame
271
+ blame -->|yes| bot
272
+ blame -->|no| owner
273
+ bot -->|no| askAuthor
274
+ bot -->|yes| owner
275
+ owner -->|yes| askOwner
276
+ owner -->|no| unassigned
277
+ ```
278
+
279
+ The brief opens with a "Who should look at this" section grouping the findings by person. A bot is never asked to review, so a Dependabot bump falls through to the declared owner. An uncommitted edit has no author yet and says so rather than guessing. A finding with neither name reads `unassigned`, which is a true statement about your repository and not a gap in the tool.
280
+
281
+ Blame names a line, not a fault. A reformat, a file move, or a bulk upgrade will put the wrong name on a finding, so the report always says where the name came from. Pass `--no-blame` to leave authors out entirely, for example if you would rather not have committer emails in a report that leaves the repository.
282
+
283
+ ## Brief
284
+
285
+ ```bash
286
+ uv run flyleaf brief main~1
287
+ uv run flyleaf brief v0.1.0 HEAD --format markdown
288
+ uv run flyleaf brief --baseline
289
+ ```
290
+
291
+ The first form compares a git ref with the working tree. The second compares two refs. The third compares the working tree against the approved baseline. `brief` exits 2 when the path is not a git repository, the ref does not resolve, or no baseline has been recorded.
292
+
293
+ A quiet brief means no component was added or removed, no detected evidence text changed, and no model card content changed. An unchanged missing card stays in `scan`. `brief` reports the delta.
294
+
295
+ ## Baseline
296
+
297
+ A baseline is the inventory as it stood at the last sign-off.
298
+
299
+ ```bash
300
+ uv run flyleaf baseline --approved-by you@example.com --rev v1.2.0
301
+ uv run flyleaf brief --baseline
302
+ ```
303
+
304
+ This writes `.flyleaf/baseline.json`. Commit it. Drift is then measured against an approved state rather than an arbitrary pair of commits, and the brief records who approved it and when.
305
+
306
+ ## Waivers
307
+
308
+ A finding is suppressed only by a written waiver in `.flyleaf/waivers.toml`. Commit that file too. It is the audit trail.
309
+
310
+ ```toml
311
+ [[waiver]]
312
+ component = "app.py:openai"
313
+ reason = "Internal prototype, not shipped. Card lands with the 1.3 release."
314
+ approved_by = "you@example.com"
315
+ expires = "2026-12-31"
316
+
317
+ [[waiver]]
318
+ component = "notebooks/train.ipynb:torch"
319
+ change = "card_stale"
320
+ reason = "Card rewrite tracked in issue 42."
321
+ approved_by = "you@example.com"
322
+ expires = "2026-11-15"
323
+ ```
324
+
325
+ `component`, `reason`, `approved_by`, and `expires` are all required. An entry missing any of them is ignored, reported as a warning, and the finding stays active. Omit `change` to cover every change on that component, or name one change to be narrower.
326
+
327
+ To waive a whole declared system, name it as `system:<name>`:
328
+
329
+ ```toml
330
+ [[waiver]]
331
+ component = "system:support-bot"
332
+ reason = "Card rewrite tracked in issue 42."
333
+ approved_by = "you@example.com"
334
+ expires = "2026-11-15"
335
+ ```
336
+
337
+ A waived finding is not deleted. It moves to the `waived` list in the output, with the reason, the approver, the expiry date, and the days remaining. When the date passes, the finding returns to `findings` with `waiver_state` set to `expired`, and the summary names the lapsed waiver. A waiver inside 14 days of expiry raises a warning so renewal is not a surprise.
338
+
339
+ ## Continuous integration
340
+
341
+ ```bash
342
+ uv run flyleaf brief --baseline --fail-on high --format sarif -o flyleaf.sarif
343
+ ```
344
+
345
+ `--fail-on` takes `none`, `low`, `medium`, or `high`, and defaults to `none`. The command exits 1 when an active finding reaches that severity, and 0 otherwise. Waived findings never trigger the exit code. A team picks its own policy, for example failing on runtime drift while only warning on documentation changes.
346
+
347
+ `--format sarif` writes SARIF 2.1.0, so GitHub renders the findings as annotations on the pull request. High maps to `error`, medium to `warning`, and low to `note`.
348
+
349
+ On GitHub, use the action:
350
+
351
+ ```yaml
352
+ permissions:
353
+ contents: read
354
+ pull-requests: write
355
+ security-events: write
356
+
357
+ steps:
358
+ - uses: actions/checkout@v7
359
+ with:
360
+ fetch-depth: 0
361
+ - uses: krishyaid-coder/flyleaf@v0.5.0
362
+ id: flyleaf
363
+ with:
364
+ baseline: "true"
365
+ fail-on: high
366
+ - uses: github/codeql-action/upload-sarif@v3
367
+ if: always()
368
+ with:
369
+ sarif_file: ${{ steps.flyleaf.outputs.sarif-file }}
370
+ ```
371
+
372
+ The action posts the brief as a pull request comment and edits that same comment on every later push, because a fresh comment per push is how a review bot teaches people to scroll past it. Set `comment: "false"` to turn it off. It needs `pull-requests: write`.
373
+
374
+ Every artefact is produced before the severity threshold is applied, so a failing check still leaves the comment and the annotations behind for the author to read.
375
+
376
+ `fetch-depth: 0` gives the action the history it needs for `git blame` and for comparing two refs. Without it, authors come back unknown.
377
+
378
+ SARIF annotations through `upload-sarif` are free on public repositories but need GitHub Advanced Security on private ones. The pull request comment works everywhere, which is why the action posts one rather than relying on annotations alone.
379
+
380
+ Pass `base` and `head` instead of `baseline` to compare two refs.
381
+
382
+ ## Render
383
+
384
+ ```bash
385
+ uv run flyleaf brief --baseline --format json -o brief.json
386
+ uv run flyleaf render brief.json --format markdown
387
+ uv run flyleaf render brief.json --format sarif -o brief.sarif
388
+ ```
389
+
390
+ `render` re-renders a saved report without scanning or reading git, so a pipeline that wants three formats pays for one scan, and an archived brief can be read back long after the branch is gone.
391
+
392
+ ## Card
393
+
394
+ ```bash
395
+ uv run flyleaf card . -o flyleaf-cards
396
+ ```
397
+
398
+ This writes one markdown scaffold per declared system, then one per component that no system claimed. The file is a draft with blanks for purpose, role, data, limitations, oversight, and the Annex III use case. A system scaffold lists every component inside it so the evidence is in one place. Existing scaffolds are kept unless you pass `--force`.
399
+
400
+ Scaffolds land under `--output` and never at a declared `card` path, so an empty draft is never counted as documentation. Move the file into place once it says something. A per-component scaffold has to be renamed to `MODEL_CARD.md` to count.
401
+
402
+ ## Cite
403
+
404
+ ```bash
405
+ uv run flyleaf cite
406
+ uv run flyleaf cite art-11-annex-iv
407
+ uv run flyleaf cite --changelog
408
+ ```
409
+
410
+ The current pack is `2026.07.27`. It cites Regulation (EU) 2024/1689 (CELEX `32024R1689`) as amended by Regulation (EU) 2026/1744 (CELEX `32026R1744`), in force 27 July 2026. The amendment deferred Chapter III, Sections 1, 2, and 3: 2 December 2027 for Annex III systems, and 2 August 2028 for Annex I systems. That date is citation `art-113-application`.
411
+
412
+ To record a later change in the law:
413
+
414
+ 1. Edit `src/flyleaf/citations.py`.
415
+ 2. Keep a superseded entry in place when a quote is replaced, and point the hint at the new id.
416
+ 3. Bump `PACK_VERSION` and add a `CHANGELOG` line that names which hint ids a person should re-read.
417
+
418
+ ## What it detects
419
+
420
+ Hosted model clients: OpenAI, Anthropic, Google GenAI, Mistral, Cohere.
421
+
422
+ Orchestration: LangChain, LlamaIndex, LangGraph.
423
+
424
+ Machine learning: PyTorch, TensorFlow, scikit-learn, Transformers, XGBoost.
425
+
426
+ ## Known limits
427
+
428
+ Detection is Python and notebooks only. TypeScript and JavaScript source files are not parsed, though their dependencies are read from `package.json`.
429
+
430
+ A component is one framework in one file, so a dependency entry and the import that uses it are two components. Declare a system to group them. Without a declaration they stay separate, because the grouping is a human judgement and flyleaf does not guess it.
431
+
432
+ A declared system is only as good as its `includes` patterns. A new file that no pattern covers is reported as a loose component, not quietly added to the nearest system.
433
+
434
+ `brief` compares the text of detected evidence, not line numbers, so moving code does not raise a finding. A change elsewhere in a manifest does not raise one either. A rename does count as a removal plus an addition.
435
+
436
+ ## Privacy
437
+
438
+ Scanning reads the local tree and, for `brief`, local git history including `git blame`. There is no telemetry, no account, and no network call. The GitHub Action is the one place anything is sent anywhere, and it posts to your own repository with your own token. Use `--no-blame` to keep committer names out of a report.
@@ -0,0 +1,18 @@
1
+ flyleaf/__init__.py,sha256=6t2XjAe96xkSQ18B909k0ziQuCs2awpD60BFe7xdDm8,380
2
+ flyleaf/attribution.py,sha256=qK4BBsw9ZM2mEP1j1caFsDGbRuac6mBOSMB88wd_g38,3035
3
+ flyleaf/baseline.py,sha256=pZQ71PbBXuV9ifor2DjKheDuW_HXdg5VlcwvORNgsnk,2095
4
+ flyleaf/brief.py,sha256=zSUSPD1Kul5T98FKl85epKSPbpjoiBhkbjZrGQVMEko,15163
5
+ flyleaf/card.py,sha256=K4puTdx1q6vLIxG0XEw37M7F6PsodwALF_WQ2mG2yJg,6037
6
+ flyleaf/citations.py,sha256=_dI2Ps1QvgQrglJHmAoNeF3QjUNWxNCGN-9C_umnUwg,7775
7
+ flyleaf/cli.py,sha256=ROKQ9FEexg7Uq4fSdyDCtt0rTAGXxHEgS9TWAKT_bBI,8701
8
+ flyleaf/report.py,sha256=hWOR6MymSoG7vrphbgXm46Ir0g9RPY6tQb2hrHsSwyk,14346
9
+ flyleaf/rules.py,sha256=ORt1qCIukaVpshuQyM4zXtRaSqhKjJMhVXETsK9ciIc,6288
10
+ flyleaf/scan.py,sha256=qeEWXYgNNLREZTsve_Kkf0zgcEDQ6qpuuo1PY8fMT0Y,16394
11
+ flyleaf/severity.py,sha256=C1nplYFNhHPLPAZuAXeP4y4yz40766kwH8EFjx3ZEdE,1413
12
+ flyleaf/systems.py,sha256=scscvBsVp83eAhduHnj_-DCHvwxHWWBlW6QLUqeTe1A,4523
13
+ flyleaf/waivers.py,sha256=bs5D67AvWquPwtHW3S9R0R37XTHHwchA5cMA3Z9Q550,3923
14
+ flyleaf-0.5.0.dist-info/licenses/LICENSE,sha256=c2EDCcj9hJx1FiMxG72uoBndn3Xn4vNnrlXEtn2tpMI,10756
15
+ flyleaf-0.5.0.dist-info/WHEEL,sha256=3iQx15CyXwGi4dbygedzA4M5T1eqO_SjwdPfUmqt2Cw,81
16
+ flyleaf-0.5.0.dist-info/entry_points.txt,sha256=AMJTiyodMjXIps-q0PBPgSW2IM_ngjvXzxAJvaT21rw,46
17
+ flyleaf-0.5.0.dist-info/METADATA,sha256=5RjJMB3rkBambM3rPRa7_BaCUwM-WBjKEpZJKYzywh4,19486
18
+ flyleaf-0.5.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: uv 0.12.24
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,3 @@
1
+ [console_scripts]
2
+ flyleaf = flyleaf.cli:main
3
+