Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions src/app/api/openrouter/[...path]/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ import {
} from '@/lib/llm-proxy-helpers';
import { getBalanceAndOrgSettings } from '@/lib/organizations/organization-usage';
import { ENABLE_TOOL_REPAIR, repairTools } from '@/lib/tool-calling';
import { isRateLimitedToDeathFree } from '@/lib/providers/openrouter';
import { isFreePromptTrainingAllowed } from '@/lib/providers/openrouter/types';
import { redactedModelResponse } from '@/lib/redactedModelResponse';
import {
Expand Down Expand Up @@ -241,10 +240,6 @@ export async function POST(request: NextRequest): Promise<NextResponseType<unkno
return modelDoesNotExistResponse();
}

if (isRateLimitedToDeathFree(originalModelIdLowerCased)) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What did this used to be for?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

to prevent people from manually modifying model ids to end in :free

return modelDoesNotExistResponse();
}

// Extract properties for usage context
Comment thread
chrarnoldus marked this conversation as resolved.
const tokenEstimates = estimateChatTokens(requestBodyParsed);
const promptInfo = extractPromptInfo(requestBodyParsed);
Expand Down
Loading