Skip to content

switch to GPT OSS 20B - #3

Merged
LukasLewandowski merged 6 commits into
masterfrom
switch-to-gpt-oss-20b
Aug 14, 2026
Merged

LukasLewandowski merged 6 commits into
masterfrom
switch-to-gpt-oss-20b

Conversation

@LukasLewandowski

@LukasLewandowski LukasLewandowski commented Aug 14, 2026 •

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • New Features

    • Added optional configuration for selecting the AI model, with a default model provided.
    • Added automated checks for code quality and successful builds on changes.
  • Bug Fixes

    • Improved AI generation request compatibility and handling of invalid themes.
    • Improved type safety and consistency across username generation.
    • Ensured theme rendering updates reliably.
  • Chores

    • Added project linting configuration and automated validation workflows.

@LukasLewandowski LukasLewandowski self-assigned this Aug 14, 2026
@qodo-code-review

Copy link
Copy Markdown

ⓘ Qodo reviews are paused because the subscription is no longer active. Ask your workspace admin to reactivate the subscription to resume reviews. Manage billing

@coderabbitai

coderabbitai Bot commented Aug 14, 2026 •

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@LukasLewandowski, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 84 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: cc543697-4899-4a33-bfd9-bb5ff79d57c9

📥 Commits

Reviewing files that changed from the base of the PR and between 79886e8 and 9c5a811.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (17)
  • .github/workflows/ci.yml
  • .github/workflows/deploy.yml
  • .prettierignore
  • .prettierrc
  • README.md
  • package.json
  • src/lib/aiUsernameGenerator.test.ts
  • src/lib/aiUsernameGenerator.ts
  • src/lib/assets/the-one-api-characters.json
  • src/lib/themes.test.ts
  • src/lib/themes.ts
  • src/lib/usernameGenerator.test.ts
  • src/lib/usernameGenerator.ts
  • src/lib/usernameVariations.test.ts
  • src/lib/usernameVariations.ts
  • src/routes/api/generate-ai/+server.ts
  • vitest.config.ts
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch switch-to-gpt-oss-20b

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@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: 79886e88bf

ℹ️ 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 thread src/routes/api/generate-ai/+server.ts Outdated
messages: [{ role: 'user' as const, content: prompt }],
max_tokens: 50,
temperature: 0.9
max_completion_tokens: 128,

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 Increase the completion budget for GPT-OSS reasoning

When GPT-OSS uses more than 128 completion tokens for its internal reasoning, those tokens consume this same budget even though include_reasoning hides them, so the response can reach finish_reason: length before producing a username. The empty-content check then silently falls back to the non-AI generator, making AI generation unreliable; use a completion budget large enough for both reasoning and the visible answer.

Useful? React with 👍 / 👎.

@coderabbitai coderabbitai 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.

🔇 Additional comments (11)
eslint.config.js (1)

1-34: LGTM!

package.json (2)

19-19: LGTM!


24-34: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

⚠️ Unverified finding
Sandbox verification was unavailable.

Commit the matching lockfile update.

This cohort adds root dev dependencies but does not update a lockfile. Line 27 of .github/workflows/ci.yml runs npm ci. npm ci requires an existing lockfile that matches package.json, or it exits before lint runs. (docs.npmjs.com)

Run this check after updating the lockfile:

src/lib/aiUsernameGenerator.ts (1)

1-1: LGTM!

src/lib/assets/oneApiCharacterNames.ts (1)

4-4: LGTM!

src/lib/usernameVariations.ts (1)

111-111: LGTM!

src/routes/+page.svelte (1)

204-204: LGTM!

.github/workflows/ci.yml (1)

17-18: 🔒 Security & Privacy

Confirm the workflow before changing checkout credentials.

The repository and .github/workflows/ci.yml are unavailable for inspection. Confirm whether later steps require authenticated Git access before adding persist-credentials: false.

src/routes/api/generate-ai/+server.ts (3)

8-8: LGTM!


24-32: LGTM!

Also applies to: 127-127


34-36: 🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

⚠️ Unverified finding
Sandbox verification was unavailable.

Make GROQ_MODEL compatible with the reasoning parameters.

GROQ_MODEL is configurable, but Lines 51-54 always send reasoning_effort: 'low' and include_reasoning: false. Groq documents low, medium, and high as reasoning settings for GPT-OSS models. A non-GPT-OSS override can therefore be rejected, and the route will use the local fallback instead of the configured model. (console.groq.com)

Either restrict GROQ_MODEL to supported GPT-OSS IDs and document that restriction in README.md Line 34, or add these fields only for GPT-OSS models. Add a test for both paths.

Proposed fix
 const GROQ_MODEL = env.GROQ_MODEL?.trim() || DEFAULT_GROQ_MODEL;
+const isGptOssModel =
+	GROQ_MODEL === 'openai/gpt-oss-20b' || GROQ_MODEL === 'openai/gpt-oss-120b';

 const groqRequest = {
 	model: GROQ_MODEL,
 	messages: [{ role: 'user' as const, content: prompt }],
 	max_completion_tokens: 128,
 	temperature: 0.9,
-	reasoning_effort: 'low' as const,
-	include_reasoning: false
+	...(isGptOssModel
+		? { reasoning_effort: 'low' as const, include_reasoning: false }
+		: {})
 };

Also applies to: 51-54


ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 0e4525c3-be56-4516-b697-2f36da25afd9

📥 Commits

Reviewing files that changed from the base of the PR and between df7b54b and 79886e8.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (9)
  • .github/workflows/ci.yml
  • README.md
  • eslint.config.js
  • package.json
  • src/lib/aiUsernameGenerator.ts
  • src/lib/assets/oneApiCharacterNames.ts
  • src/lib/usernameVariations.ts
  • src/routes/+page.svelte
  • src/routes/api/generate-ai/+server.ts

@LukasLewandowski
LukasLewandowski merged commit e746573 into master Aug 14, 2026
4 checks 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