mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-09-19 16:17:37 +03:00
Move AI Client related stuff into its own folder
This commit is contained in:
parent
91538281ec
commit
3cb86afae7
@ -1,6 +1,6 @@
|
||||
import { type AIClient, type PromptMessage, MessageRole } from '$lib/backend/aiClient';
|
||||
import { fetch, Body } from '@tauri-apps/api/http';
|
||||
import type { AnthropicModelName } from './types';
|
||||
import type { AnthropicModelName } from '../types';
|
||||
|
||||
type AnthropicAPIResponse = { content: { text: string }[] };
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { MessageRole, type AIClient, type PromptMessage } from '$lib/backend/aiClient';
|
||||
import type { CloudClient } from '$lib/backend/cloud';
|
||||
import type { ModelKind } from './types';
|
||||
import type { ModelKind } from '../types';
|
||||
|
||||
export class ButlerAIClient implements AIClient {
|
||||
constructor(
|
@ -1,5 +1,5 @@
|
||||
import { type AIClient, type PromptMessage, MessageRole } from '$lib/backend/aiClient';
|
||||
import type { OpenAIModelName } from './types';
|
||||
import type { OpenAIModelName } from '../types';
|
||||
import type OpenAI from 'openai';
|
||||
|
||||
export class OpenAIClient implements AIClient {
|
@ -1,9 +1,9 @@
|
||||
import { CloudClient } from './cloud';
|
||||
import { AnthropicModelName, ModelKind, OpenAIModelName } from './types';
|
||||
import { AnthropicAIClient } from '$lib/backend/aiClient/anthropic';
|
||||
import { ButlerAIClient } from '$lib/backend/aiClient/butler';
|
||||
import { OpenAIClient } from '$lib/backend/aiClient/openAI';
|
||||
import { AIService, GitAIConfigKey, KeyOption, buildDiff } from '$lib/backend/aiService';
|
||||
import { AnthropicAIClient } from '$lib/backend/anthropic';
|
||||
import { ButlerAIClient } from '$lib/backend/butler';
|
||||
import { OpenAIClient } from '$lib/backend/openAI';
|
||||
import * as toasts from '$lib/utils/toasts';
|
||||
import { Hunk } from '$lib/vbranches/types';
|
||||
import { plainToInstance } from 'class-transformer';
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { AnthropicModelName, OpenAIModelName } from './types';
|
||||
import { AnthropicAIClient } from '$lib/backend/anthropic';
|
||||
import { ButlerAIClient } from '$lib/backend/butler';
|
||||
import { OpenAIClient } from '$lib/backend/openAI';
|
||||
import { AnthropicAIClient } from '$lib/backend/aiClient/anthropic';
|
||||
import { ButlerAIClient } from '$lib/backend/aiClient/butler';
|
||||
import { OpenAIClient } from '$lib/backend/aiClient/openAI';
|
||||
import { splitMessage } from '$lib/utils/commitMessage';
|
||||
import * as toasts from '$lib/utils/toasts';
|
||||
import OpenAI from 'openai';
|
||||
|
Loading…
Reference in New Issue
Block a user