Extractors¶
Keys inside plugin.json's extractors[] array. See Register a metadata reader.
extractors[].exts¶
Lowercase file extensions without leading dots (for example ["png", "webp"]) that this extractor processes. When omitted, extractors with only png_text or regex default to ["png"]; command, json and page extractors match all extensions.
extractors[].png_text¶
Map of PNG text chunk keyword (tEXt, zTXt or iTXt) to target field key.
extractors[].regex¶
Regular expression rules extracting the first capture group from named PNG text chunks.
extractors[].command¶
Executable and arguments (for example ["python", "read.py", "{input}", "{parts}"]) printing a flat JSON object of field values to stdout (30 s timeout). Relative executable paths resolve against the plugin folder.
extractors[].json¶
Declarative JSON Pointer extraction over a grouped companion file (up to 8 MB).
extractors[].page¶
Relative path to a hidden HTML extractor page served from the plugin's origin (plugin:// on Linux and macOS, http://plugin.<id>.localhost/ on Windows) that handles plugin.extract via curio.extractDone (60 s timeout).
extractors[].id¶
Short reader identifier forming <plugin_id>/<id> in Field.readers, field.failures and plugin.extract. When omitted, Curio assigns x1, x2 and so on by position.
extractors[].version¶
Reader version number. Incrementing version triggers a one-time automatic rescan of matching files per library.
extractors[].fields¶
Declared output field keys populated by this extractor. Required for page extractors and recommended for command extractors so fields that are no longer returned are cleared on rescan.
extractors[].json.role¶
Companion role (declared in formats[].companions) to search for the JSON file (for example "metadata").
extractors[].json.file¶
Case-insensitive filename suffix filter matching the first companion of role whose name ends with file (for example ".civitai.info").
extractors[].json.fields¶
Map of output field key (or __title, __annotation or __source_url to fill empty item metadata) to RFC 6901 JSON Pointer (for example "/civitai/trainedWords").
extractors[].regex[].chunk¶
PNG text chunk keyword to search (for example "parameters").
extractors[].regex[].pattern¶
Regular expression whose first capture group becomes the extracted field value.
extractors[].regex[].field¶
Target field key receiving the captured string.