Skip to content

feat: close stale issues #22 #23 #25 — npm validate, dynamic version, per-engine README#81

Open
sgriffiths wants to merge 1 commit into
mainfrom
feat/cli-version-validate-readme
Open

feat: close stale issues #22 #23 #25 — npm validate, dynamic version, per-engine README#81
sgriffiths wants to merge 1 commit into
mainfrom
feat/cli-version-validate-readme

Conversation

@sgriffiths
Copy link
Copy Markdown
Contributor

Closes #22.
Closes #23.
Closes #25.

Summary

  • Add --version flag to CLI #23 — npm --version: Node CLI now reads version from package.json instead of a hard-coded literal, so oa --version cannot drift from the published release. (Python CLI already reads from package metadata since 1.5.0.)
  • Add spec validation command (oas validate) #25 — npm oa validate: Node CLI gains oa validate --spec <path>, mirroring the Python command's required-field check (open_agent_spec, agent, intelligence, tasks). No model call.
  • Add usage examples to README for each engine type #22 — Per-engine README examples: "Multiple engines" section now ships a runnable block per engine (OpenAI, Anthropic, Grok/xAI, Local, Cortex, Custom). Each shows the intelligence: YAML, the env var to export, and the matching oa run command.
  • Bumps both packages to 1.5.2 with a CHANGELOG entry.

Test plan

  • npx tsc --noEmit clean
  • ruff check oas_cli/ tests/ clean
  • pytest tests/ — 442 passed, 5 skipped
  • node ./bin/oa.js --version prints 1.5.2
  • node ./bin/oa.js validate --spec <good> exits 0; validate --spec <bad> exits 1 with VALIDATION_ERROR
  • README per-engine blocks render correctly on GitHub and PyPI

Notes

  • npm package has no existing test infra; adding jest scaffolding for one command would be scope creep — left for a follow-up.
  • .gitignore change visible in git status predates this branch and is not part of the commit.

…sion, per-engine README

- npm CLI now reads `--version` from package.json instead of a hard-coded literal (#23 npm side; Python CLI already reads from package metadata).
- npm CLI gains `oa validate --spec <path>` mirroring the Python command's required-field check, so Node users have the same pre-flight validation (#25 npm side).
- README "Multiple engines" expanded with a runnable block per engine (OpenAI, Anthropic, Grok/xAI, Local, Cortex, Custom) — `intelligence:` YAML + env var + matching `oa run` command (#22).
- Bumps both packages to 1.5.2.
@sgriffiths sgriffiths requested a review from aswhitehouse as a code owner May 11, 2026 03:32
@vercel
Copy link
Copy Markdown

vercel Bot commented May 11, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
open-agent-spec Ready Ready Preview, Comment May 11, 2026 3:33am

Request Review

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.

Add spec validation command (oas validate) Add --version flag to CLI Add usage examples to README for each engine type

1 participant