diff --git a/AGENTS.md b/AGENTS.md index cb7abe5..e375e8f 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -59,3 +59,11 @@ Every ordinary commit in a maintained Fiskwise repository goes through the share bumps the patch by **0.0.1** and stamps the date. Minor or major increments only on an **explicit user request** (`FISKWISE_VERSION_BUMP=minor|major`). Full policy: [docs/VERSIONING.md](docs/VERSIONING.md). + +## AI-use disclosure + +AI tools are not authors: never add them to `Authors@R`, `@author` or citations. Each +maintained repository discloses AI use in a "Use of generative AI" statement, and R packages +record per function which model wrote it and which last reviewed it in full. Before changing +a function recorded for another model, review it in full and report suggested changes to the +maintainer. Full policy: [docs/AI-DISCLOSURE.md](docs/AI-DISCLOSURE.md). diff --git a/CHANGELOG.md b/CHANGELOG.md index c99e212..39a0507 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 0.2.4 — 2026-11-18 + +- Add `docs/AI-DISCLOSURE.md`: AI tools are disclosed, not credited as authors; a "Use of generative AI" statement per repository, per-function AI records in R packages, and a review-before-replace rule for newer models. Linked from AGENTS.md, README.md and the managed agent instruction block. + ## 0.2.0 — 2026-11-04 - Start the 0.2 series shared by all Fiskwise knowledge packs. diff --git a/README.md b/README.md index 70a586b..7c502ce 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Fiskwise — Agentic AI tools for fisheries science -**Version 0.2.3** (2026-11-18) +**Version 0.2.4** (2026-11-18) [![Publish Fiskwise](https://github.com/DeepWaterIMR/fiskwise/actions/workflows/pages.yml/badge.svg)](https://github.com/DeepWaterIMR/fiskwise/actions/workflows/pages.yml) @@ -112,3 +112,10 @@ Every ordinary commit increments patch by **0.0.1** and records the update date. Minor (`+0.1`) and major (`+1`) versions change only at the user's explicit request. Knowledge packs use `VERSION`; R packages use DESCRIPTION `Version`/`Date`. See the [shared version policy](docs/VERSIONING.md). + +## AI-use disclosure + +AI coding assistants are disclosed, not credited as authors. Each maintained repository +carries a "Use of generative AI" statement naming the model used, and R packages record per +function which model wrote it and which last reviewed it in full. See the +[AI-disclosure policy](docs/AI-DISCLOSURE.md). diff --git a/VERSION b/VERSION index b8005b8..f1c92d4 100644 --- a/VERSION +++ b/VERSION @@ -1,2 +1,2 @@ -version: 0.2.3 +version: 0.2.4 date: 2026-11-18 diff --git a/docs/AI-DISCLOSURE.md b/docs/AI-DISCLOSURE.md new file mode 100644 index 0000000..ea61360 --- /dev/null +++ b/docs/AI-DISCLOSURE.md @@ -0,0 +1,66 @@ +# Fiskwise AI-use disclosure policy + +This policy applies to every maintained Fiskwise knowledge pack and R package. It follows +current R practice: the [CRAN Repository Policy](https://cran.r-project.org/web/packages/policies.html) +and *Writing R Extensions* define authorship roles for people and legal entities only, and +the [rOpenSci policy on generative AI](https://ropensci.org/blog/2026/02/26/ropensci-ai-policy/) +(February 2026) asks authors to *disclose* AI use and affirm that they reviewed it. + +## Credit + +- AI tools are never listed in `Authors@R`, `@author`, `CITATION`, or as `cph`. The human + maintainer stays `aut`/`cre` and is accountable for all content. +- `Co-Authored-By` trailers in commit messages remain the per-commit record of AI help. + +## Package and pack statement + +Every maintained repository carries a short **Use of generative AI** statement: +R packages in a `README.Rmd` section and on the package help page (`?pkg`, via +`@section Use of generative AI:` in `R/-package.R`); knowledge packs in a README section. + +> **Use of generative AI.** [Much of / Parts of] the code, tests and documentation in this +> [package / repository] were written with an AI coding assistant ([MODEL, VENDOR]) from the +> maintainer's prototypes and instructions. The maintainer reviewed, tested and accepted all +> AI-generated material and is responsible for it. Commits made with AI assistance carry a +> `Co-Authored-By` line in the Git history. This follows the rOpenSci policy on generative AI +> in software review. + +`[MODEL, VENDOR]` names the model that actually did the work, as model and vendor, for example +"Claude Opus 5.5, Anthropic", "GPT-6.2 Sol, OpenAI", a Google model, or a local model. An agent +knows its own model ID from its system prompt. + +## Per-function record (R packages) + +Each documented, AI-assisted exported function has a roxygen section before `@author`: + +```r +#' @section AI assistance: +#' Written with Claude Opus 5.5 (Anthropic); reviewed in full by Claude Opus +#' 5.5 (Anthropic), 2026-11-17. +``` + +Unexported helpers fall under the function that calls them. Functions from before this +policy whose model is unknown say "AI-assisted (model not recorded); not yet reviewed in +full by the current model." + +## Review before replacing a model + +A newer model replaces an older one only after it has reviewed the work: + +1. When an agent whose model differs from the one named in a record (newer, or from another + vendor) changes that function, it first reviews the **whole** function with its helpers, + tests and documentation: correctness, edge cases, statistics, and style. +2. It reports what it found to the maintainer as suggested changes and applies only the + changes the maintainer approves. +3. It then sets the record to "reviewed in full by , ". +4. An agent that does not do the full review keeps the record and appends "edited by + ". + +A full review can also be requested on its own ("review function X with the current model"). +The package statement names the models in the function records; a newer model replaces an +older one there once no record names the older model as its last full reviewer. Models from +different reviews are listed together (e.g. "Claude Opus 5.5, Anthropic; GPT-6.2 Sol, +OpenAI") until then. + +Update the statement's share ("Much of" / "Parts of") and the records in the same commit +as the work. diff --git a/scripts/lifecycle.py b/scripts/lifecycle.py index 5c2e9cc..817cf93 100644 --- a/scripts/lifecycle.py +++ b/scripts/lifecycle.py @@ -223,6 +223,9 @@ def hook_text(self): require an explicit user request; never select them autonomously. Use the repository version hook; merge/rebase replay preserves existing stamps. Full policy: {self.root / 'docs/VERSIONING.md'}. +AI tools are not authors: disclose AI use and keep per-function AI records, reviewing a +function in full before replacing another model's record: +{self.root / 'docs/AI-DISCLOSURE.md'}. Scientific methods remain with their specialist packs. Follow BAIT for IMR Biotic data and keep raw data local. Package-install consent is recorded in {self.state_file}; system software and database downloads need their own approval.