Repository navigation
Docs: update "Customizing library models for <lang>" to cover JSON data extensions - #22753
Conversation
be95f83 to
f41d6b6
Compare
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Two Go examples incorrectly target the nonexistent codeql/go pack instead of codeql/go-all.
Review effort: Balanced
Findings: 1
Open (1)
What changed in this PR
Updates library-modeling guides to document JSON data extensions while retaining YAML syntax references.
Changes:
- Adds JSON format guidance and converts examples to JSON.
- Updates JSON booleans and comment syntax.
- Updates the GitHub Actions model-pack example to load JSON files.
| File | Description |
|---|---|
| customizing-library-models-for-rust.rst | Adds Rust JSON examples. |
| customizing-library-models-for-ruby.rst | Adds Ruby JSON examples. |
| customizing-library-models-for-python.rst | Adds Python JSON examples. |
| customizing-library-models-for-javascript.rst | Adds JavaScript JSON examples. |
| customizing-library-models-for-java-and-kotlin.rst | Adds Java/Kotlin JSON examples. |
| customizing-library-models-for-go.rst | Adds Go JSON examples. |
| customizing-library-models-for-csharp.rst | Adds C# JSON examples. |
| customizing-library-models-for-cpp.rst | Adds C/C++ JSON examples. |
| customizing-library-models-for-actions.rst | Adds GitHub Actions JSON examples and configuration. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
f6d9c1e to
79cefe4
Compare
79cefe4 to
a6d96fb
Compare
|
Updated with the changes discussed offline. |
|
Very nice work @nickrolfe ! Should some from the docs team review as well? |
owen-mc
left a comment
There was a problem hiding this comment.
I didn't do the last 3 because I lost the will to live.
#19190, which originally added the Actions version of this document, was reviewed only by engineers, so I'd say there's no need.
Yes. I discovered the existence of that feature at the last minute, but it's been updated so you can have either BTW, when I convert all the existing models in the library and query packs, I plan not to touch those |
I was going to suggest the |
Why not? I think it would be confusing to use one format consistently. I believe that this feature is not documented, and it probably should be. Bonus points if you can find somewhere to document it (though hopefully not once for each language). |
No strong reasons. I was just thinking that it wouldn't make any difference to test performance, but I hadn't considered the consistency angle. It should be easy enough to find and convert them all, so I'll be happy to do so. |

The next CLI release will support JSON data extensions in addition to the existing YAML format. This PR updates the documentation to cover the JSON format and to convert all the example extensions to JSON. (JSON performs noticeably better for packs with lots of extensions).
I'll open separate PRs to convert existing models in this repository once the new CLI version is released.