Skip to content

Redefine the repository as a collection of Zod AI prompt samples#4

Open
akazah wants to merge 3 commits into
mainfrom
cursor/zod-ai-9e0b
Open

Redefine the repository as a collection of Zod AI prompt samples#4
akazah wants to merge 3 commits into
mainfrom
cursor/zod-ai-9e0b

Conversation

@akazah

@akazah akazah commented Jan 14, 2026

Copy link
Copy Markdown
Owner

Redefine the repository as a collection of Zod AI prompt samples, rewrite READMEs in English and Japanese, and restructure 4oEverPrompt as the first sample.


Open in Cursor Open in Web

cursoragent and others added 3 commits January 14, 2026 09:44
- Rewrite README in English to describe the repository as a collection
  of samples for using Zod schemas as AI prompts
- Reorganize 4oEverPrompt as a sample under samples/4oEverPrompt/
- Add sample-specific README explaining the schema features and techniques
- Update package.json with new name, description, and keywords
- Keep both English and Japanese versions of the prompt

This positions the repository as an extensible sample collection where
4oEverPrompt is the first example of using Zod schemas to structure
AI responses.

Co-authored-by: akazawa.hitoshi <akazawa.hitoshi@gmail.com>
- Add README_ja.md for main repository documentation
- Add samples/4oEverPrompt/README_ja.md for sample documentation
- Add language toggle links between English and Japanese versions

Co-authored-by: akazawa.hitoshi <akazawa.hitoshi@gmail.com>
- Add schema.ts with TypeScript schema for Structured Outputs
- Document provider-specific usage (OpenAI, Anthropic, Google, Vercel AI SDK)
- Include code examples for zodResponseFormat() and generateObject()
- Update all READMEs (English/Japanese) with Structured Outputs section
- Add usage examples in sample READMEs

This enables developers to use Zod schemas with AI provider's native
structured output features for guaranteed schema compliance.

Co-authored-by: akazawa.hitoshi <akazawa.hitoshi@gmail.com>
@cursor

cursor Bot commented Jan 14, 2026

Copy link
Copy Markdown

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@akazah akazah changed the title Zod AIプロンプトサンプル Redefine the repository as a collection of Zod AI prompt samples Jan 14, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 238313108b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +28 to +32
header: z
.string()
.describe("Header prefixed with a single positive emoji character and a space. Example: '🌟 Your Amazing Question'")
.min(20)
.max(40),

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Enforce emoji-prefixed headers in section schema

The schema description promises headers are prefixed with a single emoji and space, but the Zod validator only applies length constraints here. As a result, validateReply (and Structured Outputs that rely on this schema) will accept headers with no emoji prefix, which contradicts the stated format in this sample and the prompt-based schema. This means consumers can get “valid” outputs that fail the intended formatting requirements, especially when they rely on validation rather than prompt instructions.

Useful? React with 👍 / 👎.

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.

2 participants