[Schema Consistency] Schema Consistency Check - 2026-05-15 #32306
Closed
Replies: 1 comment
-
|
This discussion has been marked as outdated by Schema Consistency Checker. A newer discussion is available at Discussion #32580. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Overview
Automated audit of the four-way consistency between the workflow JSON schema (
pkg/parser/schemas/main_workflow_schema.json), parser/compiler code (pkg/parser,pkg/workflow), reference docs (docs/src/content/docs/reference/**), and real workflow files (.github/workflows/*.md).Four real inconsistencies surfaced this run, ranging from a missing parser bound check (a latent bug) to a built-in engine that is unreferenced in both the schema and user-facing docs. One additional finding concerns the diff generator itself producing false positives.
Summary
Critical Issues
1.
tracker-idmaxLength: 128is not enforced by the parserpkg/parser/schemas/main_workflow_schema.json:38-44): declarestracker-idas"type": "string", "minLength": 8, "maxLength": 128, "pattern": "^[a-zA-Z0-9_-]+$".pkg/workflow/frontmatter_extraction_metadata.go:86-122):extractTrackerIDvalidates the lower bound (len < 8) and the character set, but never checks the upper bound.tracker-idof 1000 characters compiles cleanly today, then gets embedded into every footer XML marker andGH_AW_TRACKER_IDenv var. It will also fail any downstream consumer that re-validates against the published schema.if len(trackerID) > 128 { return "", fmt.Errorf(...) }alongside the existing length check.2. Built-in engines
piandopencodemissing from schema descriptionpkg/workflow/agentic_engine.go:439-446): registers seven built-in engines —claude, codex, copilot, gemini, opencode, crush, pi.$defs.engine_config.oneOf[0].description): lists only five —'claude', 'codex', 'copilot', 'gemini', 'crush'. Same shortened list is repeated onengine_config.properties.id.description.docs/src/content/docs/reference/engines.md:15-21): lists six — addsopencode, still omitspi.engine: piorengine: opencodesee no IDE/schema completion or hover help for those values.engine: piappears entirely undocumented to end users despite being a registered, compiling option.engines.mdto enumerate all seven, or (b) confirmpiis internal-only and stop registering it as a built-in.Documentation Gaps
3. 16 schema top-level fields are not referenced in
frontmatter.mdThe canonical reference
docs/src/content/docs/reference/frontmatter.mdomits these schema-declared top-level fields:Full list (most are documented in other pages, but not on the main reference)
check-for-updatesfrontmatter-full.mddisable-model-invocationfrontmatter-full.mdexperimentsexperiments-specification.md,frontmatter-full.mdgithub-appsafe-outputs.md,faq.md,frontmatter-full.mdimport-schemaimports.md,frontmatter-full.md,glossary.mdinferfrontmatter-full.mdinlined-importsimports.md,faq.md,frontmatter-full.mdmax-runsengines.md,glossary.md,frontmatter-full.mdmcp-serverstools.md,faq.md, etc.modelsmodel-alias-specification.md,awf-reflect.md,frontmatter-full.mdrate-limitfrontmatter-full.md, weekly-update blog postrun-install-scriptsfrontmatter-full.mdsandboxsandbox.md,mcp-gateway.md,frontmatter-full.mdsecret-maskingfrontmatter-hash-specification.md,frontmatter-full.mdtracker-idfrontmatter-hash-specification.md,frontmatter-full.mduser-rate-limitcost-management.md,rate-limiting-controls.md,frontmatter-full.mdfrontmatter.mdas the reference (its name implies it is) will not discover these knobs.frontmatter-full.mdis auto-generated and not great as a discovery surface.frontmatter.md, pointing at the specialised reference page where one exists.Tooling Note (Schema Diff Generator)
4.
field_gaps.in_used_not_schemais full of false positivesAll 30 entries (
affected_sections,has_agent_blocks,is_smoke_test,model_adequacy,prompt_phases,setup_step_proposal,task_type,verdict,score,size, ...) come from a single workflow —.github/workflows/daily-subagent-optimizer.md— and every match lives inside fenced markdown code blocks (template prompts the agent is told to output), not in the YAML frontmatter./tmp/gh-aw/agent/schema-diff.jsonshould skip lines inside fenced code blocks (``` ... ```) when extractingused_in_workflows, or only parse the top YAML document delimited by---markers.Schema ↔ Parser Confirmed-Consistent
While auditing, the following were verified and are consistent (recording them so future runs can skip re-checking):
engine.default: "copilot"matchesconstants.DefaultEngine(pkg/constants/engine_constants.go:32).engine.versionacceptsstring|number; parser usesstringutil.ParseVersionValueto normalise both. ✓tracker-id.minLength: 8andpattern: ^[a-zA-Z0-9_-]+$are enforced inextractTrackerID. ✓Recommendations
maxLengthcheck inextractTrackerID— a 6-line code change closes the loophole.piandopencode: either fully document and add them to schema descriptions, or hide them from the registry. Today is the worst of both worlds — they work but are invisible.frontmatter.mdwith brief stubs + cross-links for the 16 fields that only exist infrontmatter-full.mdor feature-specific pages.used_in_workflowsreflects only actual frontmatter, not code-block content. This unblocks future runs from focusing on the real gaps.Strategy Performance
frontmatter.mdmaxLength/patternfieldsStrategies persisted to
/tmp/gh-aw/cache-memory/strategies.json.Next Steps
maxLength: 128check toextractTrackerIDinpkg/workflow/frontmatter_extraction_metadata.goengine_configdescription strings to list all seven built-in engines (or droppi/opencodefrom the registry)piandopencoderows todocs/src/content/docs/reference/engines.mdif both are user-facingdocs/src/content/docs/reference/frontmatter.mdReferences:
Beta Was this translation helpful? Give feedback.
All reactions