create_filter
Save reusable custom filters from Gramps rules so repeated selections run by name instead of being rebuilt. Define name, namespace, and rules to audit a scope or branch consistently.
Instructions
Save a reusable custom filter built from Gramps' own rules.
Worth doing for a selection you will run repeatedly — an audit scope, a branch of the tree — because the filter then has a name rather than being retyped each time.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"namespace": "<namespace>",
"name": "<name>",
"rules": "<rules>"
},
"name": "create_filter"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Filter name, used to apply it later. | |
| rules | Yes | Rules, each {'name': <rule>, 'values': [...], 'regex': false}. Rule names come from list_filter_rules. | |
| invert | No | Return everything the rules do NOT match. | |
| comment | No | Note on the filter's purpose. | |
| function | No | How rules combine: 'and', 'or', or 'one'. | and |
| namespace | Yes | Singular, capitalised: Person, Family, Event, Place, Citation, Source, Repository, Media, Note. |