Skip to content

Conversation

VishalNagarajan3
Copy link

No description provided.

Copy link

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

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.

ℹ️ 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 👍.

Comment on lines +12 to +13
messages = [{"role": "user", "content": "Explain quantum mechanics clearly and concisely."}]
outputs = pipe(messages, max_new_tokens=100)

Choose a reason for hiding this comment

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

P1 Badge Pass a string prompt to the text-generation pipeline

The script calls pipeline("text-generation") with messages defined as a list of role/content dictionaries and passes that list directly to pipe(...). The text-generation pipeline in Transformers expects a single prompt string (or list of strings), so this will raise a TypeError/ValueError before any generation occurs, both for the intended openai/gpt-oss-20b model and for the gpt2 fallback. Converting the message to a textual prompt (or using a chat-capable pipeline) is required for the script to run.

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.

1 participant