Skip to content

Commit

Permalink
Fixed workflow for prod, logo and added model
Browse files Browse the repository at this point in the history
  • Loading branch information
hannes-sistemica committed Nov 12, 2024
1 parent 7789987 commit d79547c
Show file tree
Hide file tree
Showing 7 changed files with 50 additions and 31 deletions.
1 change: 1 addition & 0 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
with:
context: .
file: ./Dockerfile
target: bolt-ai-production # Specify the production target
push: true
tags: |
ghcr.io/${{ github.repository }}:${{ github.sha }}
Expand Down
27 changes: 1 addition & 26 deletions app/components/chat/APIKeyManager.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,32 +18,7 @@ export const APIKeyManager: React.FC<APIKeyManagerProps> = ({ provider, apiKey,

return (
<div className="flex items-center gap-2 mt-2 mb-2">
<span className="text-sm text-bolt-elements-textSecondary">{provider} API Key:</span>
{isEditing ? (
<>
<input
type="password"
value={tempKey}
onChange={(e) => setTempKey(e.target.value)}
className="flex-1 p-1 text-sm rounded border border-bolt-elements-borderColor bg-bolt-elements-prompt-background text-bolt-elements-textPrimary focus:outline-none focus:ring-2 focus:ring-bolt-elements-focus"
/>
<IconButton onClick={handleSave} title="Save API Key">
<div className="i-ph:check" />
</IconButton>
<IconButton onClick={() => setIsEditing(false)} title="Cancel">
<div className="i-ph:x" />
</IconButton>
</>
) : (
<>
<span className="flex-1 text-sm text-bolt-elements-textPrimary">
{apiKey ? '••••••••' : 'Not set (will still work if set in .env file)'}
</span>
<IconButton onClick={() => setIsEditing(true)} title="Edit API Key">
<div className="i-ph:pencil-simple" />
</IconButton>
</>
)}
<span className="text-sm text-bolt-elements-textSecondary"></span>
</div>
);
};
3 changes: 2 additions & 1 deletion app/utils/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export const DEFAULT_MODEL = 'claude-3-5-sonnet-latest';
export const DEFAULT_PROVIDER = 'Anthropic';

const staticModels: ModelInfo[] = [
{ name: 'qwen2.5-coder:32b-32k', label: 'qwen2.5-coder:32b-32k', provider: 'Ollama' },
{ name: 'gpt-4o', label: 'GPT-4o', provider: 'OpenAI' },
{ name: 'anthropic/claude-3.5-sonnet', label: 'Anthropic: Claude 3.5 Sonnet (OpenRouter)', provider: 'OpenRouter' },
{ name: 'anthropic/claude-3-haiku', label: 'Anthropic: Claude 3 Haiku (OpenRouter)', provider: 'OpenRouter' },
Expand Down Expand Up @@ -131,4 +132,4 @@ async function initializeModelList(): Promise<void> {
MODEL_LIST = [...ollamaModels,...openAiLikeModels, ...staticModels,...lmstudioModels,];
}
initializeModelList().then();
export { getOllamaModels,getOpenAILikeModels,getLMStudioModels,initializeModelList };
export { getOllamaModels,getOpenAILikeModels,getLMStudioModels,initializeModelList };
4 changes: 4 additions & 0 deletions icons/logo-old.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/logo-text-old.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 21 additions & 1 deletion icons/logo-text.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 20 additions & 3 deletions icons/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit d79547c

Please sign in to comment.