smallcloudai / refact-intellij

Refact AI: Open-source AI Code assistant with autocompletion, chat, refactoring and more for IntelliJ JetBrains IDEs
https://refact.ai
BSD 3-Clause "New" or "Revised" License
31 stars 12 forks source link

Wrong file information #153

Open pixkk opened 2 months ago

pixkk commented 2 months ago

Hello. I have problem - when i select "Attach filename.py" and typed prompt (fix duplications in code), refact (on gpt3.5) answered me next:

image

But i dont have segment_mean function and code, which located in this function. If i select "selected *** lines", it works correctly.

MarcMcIntosh commented 2 months ago

Hello,

in the second screenshot, the lsp should have processed the @file ... command and removed it from the message after adding the file. It's posable that it may have failed to to do this.

I'll investigate further, can you confirm if the file is 10260 lines long?

MarcMcIntosh commented 2 months ago

We have recreated the issue by trying to attach a very large file.

pixkk commented 2 months ago

Although my code has changed at the moment, my code certainly did not contain 10 thousand lines at that time. Otherwise I wouldn't be able to send the entire file as a text message. I'll try again tomorrow.

pixkk commented 2 months ago

image image

(Also i use another python in this project with 260 lines of code).