Open
Conversation
Text manipulation around the text cursor
1. {{cursor}}
- Returns the text cursors current line
2. {{cursor:2:5}}
- Returns the text from...
'cursor line-2 at the start of the line' to
'cursor line+5 at the end of the line'
3. {{cursor:1:1:'[SOME_MARKER]'}}
- Like 2. but inserts [SOME_MARKER] at text cursor position
Important:
- When text is selected the cursor position is always at the end of selection
- Only one {{cursor}} marker may be included in any prompt
Why: https://huggingface.co/stabilityai/stable-code-3b#run-with-fill-in-middle-fim-%E2%9A%A1%EF%B8%8F
Author
|
The pull request might've been a little rash but i got lost in the moment whilst testing a model. My implementation lacks a comfortable integration into the rest of the project. Maybe Anyway, thanks for the awesome project. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Text manipulation around the text cursor
Important:
Why: https://huggingface.co/stabilityai/stable-code-3b#run-with-fill-in-middle-fim-%E2%9A%A1%EF%B8%8F