gograph_literals
Locates every composite-literal initialization site for a named Go struct, so you can scope the migration impact before adding a required field.
Instructions
Find every composite-literal initialization site for a named Go struct — all locations where Foo{...} syntax is used to construct the struct. WHEN TO USE: Before adding a required field to a struct — every site returned will fail to compile if the new field has no default; run this first to scope the migration blast radius. NOT TO USE: For finding string or integer magic values (use gograph_envs or grep for those); for factory functions that return the struct (use gograph_constructors). RETURNS: All file paths and line numbers where the named struct is composite-initialized; empty when the struct has no direct initialization sites.
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": {
"struct": "<struct>"
},
"name": "gograph_literals"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| root | No | Absolute path of your checkout or worktree (alias cwd). | |
| limit | No | Rows per page. | |
| cursor | No | next_cursor from the previous page. | |
| struct | Yes | The name of the struct (e.g., 'User') | |
| intention | No | Rationale; required with an active session. | |
| session_id | No | Session from session_create; omit for none. |