Description
I am having some troubles with setting context. I would like to open multiple files and have them all participate in the context used when generating inline completions.
In my test I have a folder with two files:
SchemaExport.sql
- Schema export file from a SQL databaseNewCode.sql
- Empty file where I'll be writing queries against my schema
After initialization and sign in, I do the following:
- Send a
workspace/didChangeWorkspaceFolders
notification with my folder in theadded
list - Send a
textDocument/didOpen
notification for each file in the folder - Activate the tab for
NewCode.sql
and send atextDocument/didFocus
notification - I send incremental updates using the
textDocument/didChange
notification
Inline completions work in NewCode.sql
, but the results are largely based on general SQL knowledge vs. knowledge of the contents of SchemaExport.sql
.
If I repeat the above steps, but activate the tab for SchemaExport.sql
and send a textDocument/didFocus
for it, inline completions made within SchemaExport.sql
work exactly as I expect and use the contents of the file.
How can I improve upon the context? I see similar results when opening my folder in VS Code and using Copilot there.
Thanks,
Michael