MCPcopy Index your code
hub / github.com/coder/coder / generatedAIProviderName

Function generatedAIProviderName

site/src/api/queries/chats.ts:1754–1759  ·  view source on GitHub ↗
(provider: string)

Source from the content-addressed store, hash-verified

1752};
1753
1754const generatedAIProviderName = (provider: string): string => {
1755 const suffix =
1756 globalThis.crypto?.randomUUID?.() ??
1757 `${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 10)}`;
1758 return `${provider}-${suffix}`;
1759};
1760
1761const normalizeAIProviderType = (provider: string): AIProviderType => {
1762 const normalized = provider.trim().toLowerCase();

Callers 1

createChatProviderConfigFunction · 0.85

Calls 1

nowMethod · 0.45

Tested by

no test coverage detected