Skip to content

feat: add openadapt-types dependency and _AgentOutput schema#239

Merged
abrichr merged 1 commit into
mainfrom
feat/add-openadapt-types-dep
Mar 29, 2026
Merged

feat: add openadapt-types dependency and _AgentOutput schema#239
abrichr merged 1 commit into
mainfrom
feat/add-openadapt-types-dep

Conversation

@abrichr
Copy link
Copy Markdown
Member

@abrichr abrichr commented Mar 29, 2026

Summary

  • Add openadapt-types>=0.1.0 to core dependencies — the canonical Pydantic v2 action schema for the OpenAdapt ecosystem (converges BenchmarkAction, openadapt-ml Action, omnimcp ActionDecision)
  • Add _AgentOutput Pydantic model for future Outlines JSON schema constrained decoding (outlines.json(model, _AgentOutput))
  • Does NOT change the system prompt — DSL format remains default per fix: critical TRL trainer bugs — wrong prompt, ignored task_ids, DSL parsing #236 fix

Cherry-picked from closed #237, which incorrectly replaced the DSL system prompt with JSON (re-introducing the garbage output bug fixed in #236).

When to use _AgentOutput

Once a model is SFT'd on JSON action format, switch constrained decoding from regex to JSON schema:

# Current (DSL regex, default):
constraint = outlines.regex(ACTION_REGEX)

# Future (JSON schema, after SFT on JSON):
constraint = outlines.json(_AgentOutput)

Test plan

  • 27 TRL tests pass
  • 1449 passed, 54 skipped in full suite
  • System prompt unchanged (DSL format)

🤖 Generated with Claude Code

- Add openadapt-types>=0.1.0 to core dependencies (canonical action
  schema for the OpenAdapt ecosystem — Pydantic v2, lightweight)
- Add _AgentOutput Pydantic model for future Outlines JSON schema
  constrained decoding (currently unused — default is DSL regex)
- Does NOT change the system prompt (DSL format, matching #236 fix)

The _AgentOutput model enables switching to outlines.json(model, schema)
once models are SFT'd on JSON format. For now, DSL regex remains default.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@abrichr abrichr merged commit fb7e87f into main Mar 29, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant