Skip to content

fix(skippy): treat zero-temperature sampling as greedy - #1143

Merged
ndizazzo merged 1 commit into
mainfrom
agent/skippy-zero-temperature-greedy
Aug 4, 2026
Merged

fix(skippy): treat zero-temperature sampling as greedy#1143
ndizazzo merged 1 commit into
mainfrom
agent/skippy-zero-temperature-greedy

Conversation

@i386

@i386 i386 commented Aug 2, 2026

Copy link
Copy Markdown
Collaborator

Problem

OpenAI clients commonly use temperature: 0 when they need reproducible output. Skippy still classified those requests as stochastic whenever sampling was enabled, so it rejected verified linear proposals even when no sampling option could change the winning token.

That meant a deterministic request behaved differently depending on whether the client omitted sampling settings or explicitly requested zero temperature.

Fix

Admission now depends on whether the request can actually change greedy token selection. Zero temperature with neutral penalties and no logit bias is treated as deterministic. Non-zero temperature, grammar-constrained sampling, penalties, and logit bias remain excluded.

This keeps the safety boundary narrow: proposals are admitted only when verification is equivalent to greedy decoding, without special-casing a particular model or client.

Validation

Skippy Server tests pass (353/353), including deterministic and stochastic sampling cases.

Summary by CodeRabbit

  • Bug Fixes
    • Improved linear proposal handling for generation requests.
    • Deterministic, zero-temperature sampling is now supported when no penalties or bias adjustments are applied.
    • Requests using stochastic sampling or logit-modifying settings continue to be handled appropriately.

@github-actions

github-actions Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

This pull request is currently a draft. Reviews will not take place until the PR is marked as ready for review.

@coderabbitai

coderabbitai Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c789bda4-a659-4a9b-a96a-7abf7ea4d880

📥 Commits

Reviewing files that changed from the base of the PR and between 4d289b0 and 42b7fdf.

📒 Files selected for processing (2)
  • crates/skippy-server/src/frontend/linear_proposal.rs
  • crates/skippy-server/src/frontend/local_generation.rs
🚧 Files skipped from review as they are similar to previous changes (2)
  • crates/skippy-server/src/frontend/local_generation.rs
  • crates/skippy-server/src/frontend/linear_proposal.rs

📝 Walkthrough

Walkthrough

Linear proposal admission now evaluates the complete SamplingConfig. Greedy-equivalent settings remain eligible, while stochastic or logit-modified settings are rejected. Local generation passes the full configuration to the admission check.

Changes

Sampling-aware linear proposal admission

Layer / File(s) Summary
Sampling configuration admission
crates/skippy-server/src/frontend/linear_proposal.rs
greedy_linear_proposal_admitted evaluates sampling enablement, temperature, penalties, repeat penalty, and logit bias. Tests cover disabled, zero-temperature, stochastic, logit-biased, and grammar metadata configurations.
Local generation integration
crates/skippy-server/src/frontend/local_generation.rs
Local generation passes the complete sampling configuration to linear proposal admission.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

Suggested labels: experimental

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: zero-temperature sampling is treated as greedy for proposal admission.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ 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 agent/skippy-zero-temperature-greedy

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.

@i386
i386 marked this pull request as ready for review August 2, 2026 06:28
@github-actions
github-actions Bot requested a review from michaelneale August 2, 2026 06:28
@i386
i386 force-pushed the agent/skippy-zero-temperature-greedy branch from 27a32e4 to e5171e9 Compare August 2, 2026 07:37
@ndizazzo
ndizazzo force-pushed the agent/skippy-zero-temperature-greedy branch from e5171e9 to 4d289b0 Compare August 4, 2026 00:48

@michaelneale michaelneale left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Low risk: local speculative-verification admission only, invisible across versions. Zero-temp treated as greedy is a correct, well-scoped change. LGTM.

@ndizazzo
ndizazzo force-pushed the agent/skippy-zero-temperature-greedy branch from 4d289b0 to 42b7fdf Compare August 4, 2026 02:42
@ndizazzo
ndizazzo merged commit 66c40d6 into main Aug 4, 2026
45 checks passed
@ndizazzo
ndizazzo deleted the agent/skippy-zero-temperature-greedy branch August 4, 2026 03:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants