-
-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clean up GPT Grammar #80
Conversation
Examples: When the order is reversed I think we need |
@jaresty with this grammar you can essentially have the model have state and respond in any fashion you please i.e. in the context of coding
in the context of writing a research paper |
This looks really powerful. I'll give it a test run when I can. Excited! Thanks. |
Should we change the model blend grammar to match this too? |
for more information, see https://pre-commit.ci
I think that is out of scope for this PR at least on my end. It could fit in the grammar but you would have to do some if statement checking in python that gets a little messy/tedious to match all the cases. |
I'm mostly thinking it would make sense to just change the "model blend clip" into "on clip model blend" to reduce interference. It wouldn't have to handle all cases, just to avoid having to keep a different mental model for the one command. |
There's something bit weird about the way it is matching. I didn't expect it to match this: |
I played with it a bit and it's great. I really loved the power of being able to pipeline transformations. I ran into a couple of issues that are somewhat orthogonal to this pull request:
|
One thought on the grammar with respect to cursorless. In cursorless we usually say "verb target to destination". This grammar is essentially "on target responding destination verb". It might be more cursorless-like to reorder it. You could probably even use the cursorless grammar and just have these act as virtual targets/destinations. Something like: "model summarize clip/last to clip/window" |
for more information, see https://pre-commit.ci
Should be fixed now. Seems like it matched a cursorless tag. Moved the cursorless target into the cursorless specific file. |
One of my goals with pipelining is to allow easier use of model please for arbitrary requests. (and integrate it better alongside the static prompts in a format that is more consistent) Model please doesn't flow particularly well if you have arbitrary user requested text in the middle, and then have to break out of it at the very end of the phrase to say a specific keyword. That was my main justification for it is at the end. |
Got it. That is a good point. I'm curious to hear thoughts from @pokey on this one. I'm also interested in adding a way to add additional textual context to every prompt, so this grammar does solve that nicely. |
Fwiw, one way you could use cursorless grammar and allow for adding arbitrary text at the end could be to use a conjunction like "and". Example:
|
Pokey and I discussed this a lot today.
Some of these might alter some workflows but Pokey and I agreed that we wanted to support a grammar that mimics the |
Quick note: "model take that" would be more cursorless-like than "model take last" |
Yeah honestly I think I'm going to change it to be Pokey and I did discuss this during the meet up and I thought |
I think I like "last" since it also is used as a target |
Btw, I was using selected/below quite a bit. Hope there's something analogous in the new grammar |
Aside-it would be nice if there were a way to view the clipboard contents in a browser window (model view clipboard?) since we sometimes put things into it without ever seeing them. |
Below is the same. Pokey recommended removing selected and just using I think for the time being if you want to select it in advance it would make sense to create a simple custom command for it. In the future we can think about another PR for destination modifiers |
If you feel strongly and you really need selected to be a part of the destination grammar then I can just keep it in though |
I do really appreciate having it-it acts almost like a working memory. Have you ever seen a clipboard ring? It reminds me of that (example: https://marketplace.visualstudio.com/items?itemName=SirTobi.code-clip-ring) |
Ideally, I think it would be an optional addendum to pasted destinations like before, after, and pasting with no modifiers, since it is more of a behavioral modification than a destination, really. I'm ok making do with whatever you decide, however. I had been relying on it as a way to transform the last prompt result while I can still look at it (since last and clipboard end up invisible to the user) |
For the time being I think I would prefer if you use a custom command for selection in your repo. i.e. the one below
You can also just chain it by saying |
Ok. I'll use that. |
We also now have |
Merging this. I will talk with Pokey again in the future and get his feedback and then we can iterate if you are unhappy or thing the grammar should be made more complex. I've myself refrained from adding some things that might be useful for my own workflow just since I am trying to make the repo a bit more generalized and fitting to a clear, predictable grammar. Hope this tradeoff is reasonable. |
last
as a sourceverbal
as a response option if TTS is installedbrowser
towindowed
to fit the adverb grammar betteruser.text
at the end, allowing for easier chaining and better recognition.