Strategies
Strategies are reusable “finalization steps” that run after an AIKP produces outputs. They exist to keep the workflow consistent across AIKPs while still allowing AIKP-specific overrides.
Why strategies exist
Most AIKP workflows need the same three post-processing steps:
makegeojson
Produces the UI/DB-facing metadata document.
This metadata connects the output artifact(s) to the UI by describing where files live (COS keys/URLs), how they should be displayed, and what the document bounding geometry is.
upload
Uploads the produced artifacts (and the generated metadata) to Cloud Object Storage (COS).
publish
Registers (posts) the metadata document into the documents database so it becomes visible/available in the UI.
The strategy layer exists so:
AIKPs can share the same default implementation of these steps.
AIKPs can override only the parts they need, without re-implementing the whole CLI workflow.
What strategies exist
Vector strategies
Vector strategies are reusable implementations specifically for AIKPs that produce vector outputs.
Overview and usage: Vector Strategies
Default (core) strategies
Default strategies are the core implementations used when an AIKP does not override behavior.
How defaults work internally: Default Strategies
How to use strategies (CLI)
The standard “finalization pipeline” is:
Create metadata:
ai makegeojson
# optional examples
ai makegeojson --friendly-name "My Layer"
ai makegeojson --cos-key "+v2"
Upload artifacts + metadata to COS:
ai upload
# or
ai upload --dry-run
Publish the metadata document to the docs DB:
publish post
# or
publish post --dry-run
Notes:
--cos-keyand--friendly-nameare commonly used to override identity without changing recipe defaults.If
--friendly-nameor--cos-keystarts with+, it is treated as a suffix.
How to create custom strategies
AIKPs can override strategies in a supported way (recommended), or via a legacy module mapping approach.
See Custom Strategies for both approaches and the expected method/module shapes.