Skip to content

Commit 571a839

Browse files
committed
Aider 3
1 parent 5886a84 commit 571a839

File tree

3 files changed

+8
-7
lines changed

3 files changed

+8
-7
lines changed

core/llm/llms/Aider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ public async aiderResetSession(model: string, apiKey: string | undefined): Promi
468468
}
469469

470470
async listModels(): Promise<string[]> {
471-
return ["aider", "claude-3-5-sonnet-20240620", "pearai_model", "gpt-4o"];
471+
return ["claude-3-5-sonnet-20240620", "pearai_model", "gpt-4o"];
472472
}
473473

474474
supportsFim(): boolean {

gui/src/components/mainInput/TipTapEditor.tsx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ import {
5757
} from "./getSuggestion";
5858
import { ComboBoxItem } from "./types";
5959
import { isBareChatMode } from '../../util/bareChatMode';
60+
import { useLocation } from "react-router-dom";
6061

6162

6263
const InputBoxDiv = styled.div`
@@ -117,8 +118,9 @@ const HoverTextDiv = styled.div`
117118
justify-content: center;
118119
`;
119120

120-
const getPlaceholder = (defaultModel, historyLength: number) => {
121-
if (defaultModel?.title?.toLowerCase().includes("aider")) {
121+
122+
const getPlaceholder = (historyLength: number, location: Location | null) => {
123+
if (location?.pathname === "/aiderMode") {
122124
return historyLength === 0
123125
? "Ask me to create, change, or fix anything..."
124126
: "Send a follow-up";
@@ -310,7 +312,7 @@ function TipTapEditor(props: TipTapEditorProps) {
310312
},
311313
}),
312314
Placeholder.configure({
313-
placeholder: () => getPlaceholder(defaultModel, historyLengthRef.current),
315+
placeholder: () => getPlaceholder(historyLengthRef.current, location),
314316
}),
315317
Paragraph.extend({
316318
addKeyboardShortcuts() {
@@ -483,7 +485,7 @@ function TipTapEditor(props: TipTapEditorProps) {
483485
});
484486

485487
const editorFocusedRef = useUpdatingRef(editor?.isFocused, [editor]);
486-
488+
487489
useEffect(() => {
488490
const handleShowFile = (event: CustomEvent) => {
489491
const filepath = event.detail.filepath;
@@ -495,7 +497,7 @@ function TipTapEditor(props: TipTapEditorProps) {
495497
window.removeEventListener('showFile', handleShowFile as EventListener);
496498
};
497499
}, [ideMessenger]);
498-
500+
499501
useEffect(() => {
500502
if (isJetBrains()) {
501503
// This is only for VS Code .ipynb files

gui/src/components/markdown/FileCreateChip.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ const FileCreateChip = ({ rawCodeBlock }) => {
4545
// try {
4646
// // this does not work, dont waste your time - promise never resolves
4747
// const response = await ideMessenger.ide.fileExists(filePath);
48-
// console.dir("aldsfjkalsdfjk")
4948
// setFileExists(response);
5049
// } catch (error) {
5150
// console.error(`Error checking file existence: ${error}`);

0 commit comments

Comments
 (0)