remove parrot.nvim and clean up nixpkgs follows
This commit is contained in:
parent
502ae1a4a3
commit
a67d5981ec
58
flake.lock
generated
58
flake.lock
generated
@ -164,38 +164,6 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs_3": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1744868846,
|
|
||||||
"narHash": "sha256-5RJTdUHDmj12Qsv7XOhuospjAjATNiTMElplWnJE9Hs=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "ebe4301cbd8f81c4f8d3244b3632338bbeb6d49c",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"ref": "nixpkgs-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_4": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1747958103,
|
|
||||||
"narHash": "sha256-qmmFCrfBwSHoWw7cVK4Aj+fns+c54EBP8cGqp/yK410=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "fe51d34885f7b5e3e7b59572796e1bcb427eccb1",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixpkgs-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nomodoro": {
|
"nomodoro": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
@ -230,23 +198,6 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"parrot-nvim": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1748727208,
|
|
||||||
"narHash": "sha256-HlZF5HvbivH6Kh5AgoZfO+q/d5KF1vU37fudu095LuE=",
|
|
||||||
"owner": "frankroeder",
|
|
||||||
"repo": "parrot.nvim",
|
|
||||||
"rev": "378d7706a392c06eabe0ddbbdc6ed5fa57ca4db0",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "frankroeder",
|
|
||||||
"ref": "main",
|
|
||||||
"repo": "parrot.nvim",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"pyproject-build-systems": {
|
"pyproject-build-systems": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
@ -308,7 +259,6 @@
|
|||||||
"nixpkgs-24-11": "nixpkgs-24-11",
|
"nixpkgs-24-11": "nixpkgs-24-11",
|
||||||
"nomodoro": "nomodoro",
|
"nomodoro": "nomodoro",
|
||||||
"nvim-web-devicons": "nvim-web-devicons",
|
"nvim-web-devicons": "nvim-web-devicons",
|
||||||
"parrot-nvim": "parrot-nvim",
|
|
||||||
"sops-nix": "sops-nix",
|
"sops-nix": "sops-nix",
|
||||||
"spaceport-nvim": "spaceport-nvim",
|
"spaceport-nvim": "spaceport-nvim",
|
||||||
"systems": "systems",
|
"systems": "systems",
|
||||||
@ -318,7 +268,9 @@
|
|||||||
},
|
},
|
||||||
"sops-nix": {
|
"sops-nix": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": "nixpkgs_3"
|
"nixpkgs": [
|
||||||
|
"nixpkgs-24-11"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1747603214,
|
"lastModified": 1747603214,
|
||||||
@ -385,7 +337,9 @@
|
|||||||
},
|
},
|
||||||
"treefmt-nix_2": {
|
"treefmt-nix_2": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": "nixpkgs_4"
|
"nixpkgs": [
|
||||||
|
"nixpkgs-24-11"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1748243702,
|
"lastModified": 1748243702,
|
||||||
|
21
flake.nix
21
flake.nix
@ -5,8 +5,15 @@
|
|||||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||||
nixpkgs-24-11.url = "github:NixOS/nixpkgs/nixos-24.11";
|
nixpkgs-24-11.url = "github:NixOS/nixpkgs/nixos-24.11";
|
||||||
|
|
||||||
treefmt-nix.url = "github:numtide/treefmt-nix";
|
treefmt-nix = {
|
||||||
sops-nix.url = "github:Mic92/sops-nix";
|
url = "github:numtide/treefmt-nix";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs-24-11";
|
||||||
|
};
|
||||||
|
|
||||||
|
sops-nix = {
|
||||||
|
url = "github:Mic92/sops-nix";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs-24-11";
|
||||||
|
};
|
||||||
|
|
||||||
NixOS-WSL-2411 = {
|
NixOS-WSL-2411 = {
|
||||||
url = "github:nix-community/NixOS-WSL";
|
url = "github:nix-community/NixOS-WSL";
|
||||||
@ -28,10 +35,10 @@
|
|||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
parrot-nvim = {
|
# parrot-nvim = {
|
||||||
url = "github:frankroeder/parrot.nvim/main";
|
# url = "github:frankroeder/parrot.nvim/main";
|
||||||
flake = false;
|
# flake = false;
|
||||||
};
|
# };
|
||||||
|
|
||||||
nomodoro = {
|
nomodoro = {
|
||||||
url = "github:dbinagi/nomodoro/main";
|
url = "github:dbinagi/nomodoro/main";
|
||||||
@ -77,7 +84,7 @@
|
|||||||
inherit spaceport-nvim;
|
inherit spaceport-nvim;
|
||||||
inherit inputs;
|
inherit inputs;
|
||||||
inherit nomodoro;
|
inherit nomodoro;
|
||||||
parrot-nvim = inputs.parrot-nvim;
|
# parrot-nvim = inputs.parrot-nvim;
|
||||||
}).overlay;
|
}).overlay;
|
||||||
# Small tool to iterate over each systems
|
# Small tool to iterate over each systems
|
||||||
eachSystem = f: nixpkgs.lib.genAttrs (import systems) (system: f nixpkgs.legacyPackages.${system});
|
eachSystem = f: nixpkgs.lib.genAttrs (import systems) (system: f nixpkgs.legacyPackages.${system});
|
||||||
|
@ -195,7 +195,7 @@ in
|
|||||||
pkgs.customVimPlugins.cmp-vimtex
|
pkgs.customVimPlugins.cmp-vimtex
|
||||||
# pkgs.customVimPlugins.spaceport-nvim
|
# pkgs.customVimPlugins.spaceport-nvim
|
||||||
pkgs.customVimPlugins.nomodoro
|
pkgs.customVimPlugins.nomodoro
|
||||||
pkgs.customVimPlugins.parrot-nvim
|
# pkgs.customVimPlugins.parrot-nvim
|
||||||
pkgs.customVimPlugins.nvim-web-devicons
|
pkgs.customVimPlugins.nvim-web-devicons
|
||||||
|
|
||||||
# syntax highlighting
|
# syntax highlighting
|
||||||
|
@ -92,170 +92,170 @@
|
|||||||
vim.g.vimtex_fold_enabled = true
|
vim.g.vimtex_fold_enabled = true
|
||||||
|
|
||||||
${builtins.readFile ./overseer.lua}
|
${builtins.readFile ./overseer.lua}
|
||||||
require("parrot").setup({
|
# require("parrot").setup({
|
||||||
providers = {
|
# providers = {
|
||||||
anthropic = {
|
# anthropic = {
|
||||||
api_key = { "cat", "${config.sops.secrets.anthropic_api_key.path}" },
|
# api_key = { "cat", "${config.sops.secrets.anthropic_api_key.path}" },
|
||||||
},
|
# },
|
||||||
},
|
# },
|
||||||
hooks = {
|
# hooks = {
|
||||||
Complete = function(prt, params)
|
# Complete = function(prt, params)
|
||||||
local template = [[
|
# local template = [[
|
||||||
I have the following code from {{filename}}:
|
# I have the following code from {{filename}}:
|
||||||
|
#
|
||||||
```{{filetype}}
|
# ```{{filetype}}
|
||||||
{{selection}}
|
# {{selection}}
|
||||||
```
|
# ```
|
||||||
|
#
|
||||||
Please finish the code above carefully and logically.
|
# Please finish the code above carefully and logically.
|
||||||
Respond just with the snippet of code that should be inserted."
|
# Respond just with the snippet of code that should be inserted."
|
||||||
]]
|
# ]]
|
||||||
local model_obj = prt.get_model "command"
|
# local model_obj = prt.get_model "command"
|
||||||
prt.Prompt(params, prt.ui.Target.append, model_obj, nil, template)
|
# prt.Prompt(params, prt.ui.Target.append, model_obj, nil, template)
|
||||||
end,
|
# end,
|
||||||
CompleteFullContext = function(prt, params)
|
# CompleteFullContext = function(prt, params)
|
||||||
local template = [[
|
# local template = [[
|
||||||
I have the following code from {{filename}}:
|
# I have the following code from {{filename}}:
|
||||||
|
#
|
||||||
```{{filetype}}
|
# ```{{filetype}}
|
||||||
{{filecontent}}
|
# {{filecontent}}
|
||||||
```
|
# ```
|
||||||
|
#
|
||||||
Please look at the following section specifically:
|
# Please look at the following section specifically:
|
||||||
```{{filetype}}
|
# ```{{filetype}}
|
||||||
{{selection}}
|
# {{selection}}
|
||||||
```
|
# ```
|
||||||
|
#
|
||||||
Please finish the code above carefully and logically.
|
# Please finish the code above carefully and logically.
|
||||||
Respond just with the snippet of code that should be inserted.
|
# Respond just with the snippet of code that should be inserted.
|
||||||
]]
|
# ]]
|
||||||
local model_obj = prt.get_model "command"
|
# local model_obj = prt.get_model "command"
|
||||||
prt.Prompt(params, prt.ui.Target.append, model_obj, nil, template)
|
# prt.Prompt(params, prt.ui.Target.append, model_obj, nil, template)
|
||||||
end,
|
# end,
|
||||||
CompleteMultiContext = function(prt, params)
|
# CompleteMultiContext = function(prt, params)
|
||||||
local template = [[
|
# local template = [[
|
||||||
I have the following code from {{filename}} and other realted files:
|
# I have the following code from {{filename}} and other realted files:
|
||||||
|
#
|
||||||
```{{filetype}}
|
# ```{{filetype}}
|
||||||
{{multifilecontent}}
|
# {{multifilecontent}}
|
||||||
```
|
# ```
|
||||||
|
#
|
||||||
Please look at the following section specifically:
|
# Please look at the following section specifically:
|
||||||
```{{filetype}}
|
# ```{{filetype}}
|
||||||
{{selection}}
|
# {{selection}}
|
||||||
```
|
# ```
|
||||||
|
#
|
||||||
Please finish the code above carefully and logically.
|
# Please finish the code above carefully and logically.
|
||||||
Respond just with the snippet of code that should be inserted.
|
# Respond just with the snippet of code that should be inserted.
|
||||||
]]
|
# ]]
|
||||||
local model_obj = prt.get_model "command"
|
# local model_obj = prt.get_model "command"
|
||||||
prt.Prompt(params, prt.ui.Target.append, model_obj, nil, template)
|
# prt.Prompt(params, prt.ui.Target.append, model_obj, nil, template)
|
||||||
end,
|
# end,
|
||||||
Explain = function(prt, params)
|
# Explain = function(prt, params)
|
||||||
local template = [[
|
# local template = [[
|
||||||
Your task is to take the code snippet from {{filename}} and explain it with gradually increasing complexity.
|
# Your task is to take the code snippet from {{filename}} and explain it with gradually increasing complexity.
|
||||||
Break down the code's functionality, purpose, and key components.
|
# Break down the code's functionality, purpose, and key components.
|
||||||
The goal is to help the reader understand what the code does and how it works.
|
# The goal is to help the reader understand what the code does and how it works.
|
||||||
|
#
|
||||||
```{{filetype}}
|
# ```{{filetype}}
|
||||||
{{selection}}
|
# {{selection}}
|
||||||
```
|
# ```
|
||||||
|
#
|
||||||
Use the markdown format with codeblocks and inline code.
|
# Use the markdown format with codeblocks and inline code.
|
||||||
Explanation of the code above:
|
# Explanation of the code above:
|
||||||
]]
|
# ]]
|
||||||
local model = prt.get_model "command"
|
# local model = prt.get_model "command"
|
||||||
prt.logger.info("Explaining selection with model: " .. model.name)
|
# prt.logger.info("Explaining selection with model: " .. model.name)
|
||||||
prt.Prompt(params, prt.ui.Target.new, model, nil, template)
|
# prt.Prompt(params, prt.ui.Target.new, model, nil, template)
|
||||||
end,
|
# end,
|
||||||
ProofReader = function(prt, params)
|
# ProofReader = function(prt, params)
|
||||||
local chat_prompt = [[
|
# local chat_prompt = [[
|
||||||
I want you to act as a proofreader. I will provide you with texts and
|
# I want you to act as a proofreader. I will provide you with texts and
|
||||||
I would like you to review them for any spelling, grammar, or
|
# I would like you to review them for any spelling, grammar, or
|
||||||
punctuation errors. Once you have finished reviewing the text,
|
# punctuation errors. Once you have finished reviewing the text,
|
||||||
provide me with any necessary corrections or suggestions to improve the
|
# provide me with any necessary corrections or suggestions to improve the
|
||||||
text. Highlight the corrected fragments (if any) using markdown backticks.
|
# text. Highlight the corrected fragments (if any) using markdown backticks.
|
||||||
|
#
|
||||||
When you have done that subsequently provide me with a slightly better
|
# When you have done that subsequently provide me with a slightly better
|
||||||
version of the text, but keep close to the original text.
|
# version of the text, but keep close to the original text.
|
||||||
|
#
|
||||||
Finally provide me with an ideal version of the text.
|
# Finally provide me with an ideal version of the text.
|
||||||
|
#
|
||||||
For each of these versions, you can elide sections which include long unchanged text with NO_CHANGES_HERE.
|
# For each of these versions, you can elide sections which include long unchanged text with NO_CHANGES_HERE.
|
||||||
|
#
|
||||||
Whenever I provide you with text, you reply in this format directly:
|
# Whenever I provide you with text, you reply in this format directly:
|
||||||
|
#
|
||||||
|
#
|
||||||
## Summary of suggestions:
|
# ## Summary of suggestions:
|
||||||
|
#
|
||||||
{a brief list of spelling, grammar and punctuation errors, with brief snippets of the original text so I can search and find each change, followed by summaries of what types of changes are in the slightly better and ideal versions}
|
# {a brief list of spelling, grammar and punctuation errors, with brief snippets of the original text so I can search and find each change, followed by summaries of what types of changes are in the slightly better and ideal versions}
|
||||||
|
#
|
||||||
## Corrected text:
|
# ## Corrected text:
|
||||||
|
#
|
||||||
{corrected text, or say "NO_CORRECTIONS_NEEDED" instead if there are no corrections made}
|
# {corrected text, or say "NO_CORRECTIONS_NEEDED" instead if there are no corrections made}
|
||||||
|
#
|
||||||
## Slightly better text
|
# ## Slightly better text
|
||||||
|
#
|
||||||
{slightly better text}
|
# {slightly better text}
|
||||||
|
#
|
||||||
## Ideal text
|
# ## Ideal text
|
||||||
|
#
|
||||||
{ideal text}
|
# {ideal text}
|
||||||
]]
|
# ]]
|
||||||
prt.ChatNew(params, chat_prompt)
|
# prt.ChatNew(params, chat_prompt)
|
||||||
end,
|
# end,
|
||||||
ProofReader2 = function(prt, params)
|
# ProofReader2 = function(prt, params)
|
||||||
local chat_prompt = [[
|
# local chat_prompt = [[
|
||||||
I want you to act as a professional proofreader and editor. When I provide you with text, please:
|
# I want you to act as a professional proofreader and editor. When I provide you with text, please:
|
||||||
|
#
|
||||||
1. First, identify and correct errors in
|
# 1. First, identify and correct errors in
|
||||||
- spelling
|
# - spelling
|
||||||
- grammar
|
# - grammar
|
||||||
- punctuation
|
# - punctuation
|
||||||
- syntax errors.
|
# - syntax errors.
|
||||||
- Technical accuracy (for domain-specific content especially)
|
# - Technical accuracy (for domain-specific content especially)
|
||||||
Mark corrections using markdown backticks.
|
# Mark corrections using markdown backticks.
|
||||||
|
#
|
||||||
2. Second, analyze stylistic elements including
|
# 2. Second, analyze stylistic elements including
|
||||||
- clarity
|
# - clarity
|
||||||
- conciseness
|
# - conciseness
|
||||||
- word choice
|
# - word choice
|
||||||
- sentence structure
|
# - sentence structure
|
||||||
- paragraph organization and transitions (as appropriate for text length)
|
# - paragraph organization and transitions (as appropriate for text length)
|
||||||
|
#
|
||||||
3. Provide your response in this structured format:
|
# 3. Provide your response in this structured format:
|
||||||
|
#
|
||||||
# Summary of the text:
|
# # Summary of the text:
|
||||||
Provide a concise overview of the text (1-2 sentences).
|
# Provide a concise overview of the text (1-2 sentences).
|
||||||
For longer texts (5+ paragraphs), include a brief outline of the content.
|
# For longer texts (5+ paragraphs), include a brief outline of the content.
|
||||||
|
#
|
||||||
|
#
|
||||||
## Summary of suggestions:
|
# ## Summary of suggestions:
|
||||||
- List specific errors found with brief context
|
# - List specific errors found with brief context
|
||||||
- Group similar issues together
|
# - Group similar issues together
|
||||||
- Note patterns if they exist
|
# - Note patterns if they exist
|
||||||
- Highlight 3-5 most impactful improvements
|
# - Highlight 3-5 most impactful improvements
|
||||||
- Summarize the types of improvements made in each version
|
# - Summarize the types of improvements made in each version
|
||||||
|
#
|
||||||
## Corrected text:
|
# ## Corrected text:
|
||||||
Present the text with technical errors fixed (or state "NO_CORRECTIONS_NEEDED" if appropriate)
|
# Present the text with technical errors fixed (or state "NO_CORRECTIONS_NEEDED" if appropriate)
|
||||||
|
#
|
||||||
## Enhanced text:
|
# ## Enhanced text:
|
||||||
Provide a version with moderate improvements to readability and flow while preserving the original voice and style. You may use [NO_CHANGES_HERE] to indicate substantial unchanged sections to keep your response more concise.
|
# Provide a version with moderate improvements to readability and flow while preserving the original voice and style. You may use [NO_CHANGES_HERE] to indicate substantial unchanged sections to keep your response more concise.
|
||||||
|
#
|
||||||
## Optimal text:
|
# ## Optimal text:
|
||||||
Present an ideal version that maintains the original intent but optimizes for clarity, impact, and professional quality. Use [NO_CHANGES_HERE] as mentioned above.
|
# Present an ideal version that maintains the original intent but optimizes for clarity, impact, and professional quality. Use [NO_CHANGES_HERE] as mentioned above.
|
||||||
|
#
|
||||||
Please maintain the original meaning and tone while making your suggestions. If you're uncertain about the author's intent in any section, note this and provide alternative interpretations.
|
# Please maintain the original meaning and tone while making your suggestions. If you're uncertain about the author's intent in any section, note this and provide alternative interpretations.
|
||||||
For very long texts, focus on the most impactful improvements.
|
# For very long texts, focus on the most impactful improvements.
|
||||||
]]
|
# ]]
|
||||||
prt.ChatNew(params, chat_prompt)
|
# prt.ChatNew(params, chat_prompt)
|
||||||
|
#
|
||||||
end,
|
# end,
|
||||||
},
|
# },
|
||||||
})
|
# })
|
||||||
|
#
|
||||||
vim.api.nvim_set_keymap("n", "<leader>pt", "<cmd>PrtChatToggle<CR>", { noremap = true})
|
# vim.api.nvim_set_keymap("n", "<leader>pt", "<cmd>PrtChatToggle<CR>", { noremap = true})
|
||||||
|
|
||||||
require("nomodoro").setup({
|
require("nomodoro").setup({
|
||||||
work_time = 10,
|
work_time = 10,
|
||||||
|
@ -26,7 +26,7 @@ require("lualine").setup({
|
|||||||
icons_enabled = false,
|
icons_enabled = false,
|
||||||
},
|
},
|
||||||
require("nomodoro").status,
|
require("nomodoro").status,
|
||||||
parrot_status,
|
-- parrot_status,
|
||||||
},
|
},
|
||||||
lualine_x = {
|
lualine_x = {
|
||||||
"encoding",
|
"encoding",
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
cmp-vimtex,
|
cmp-vimtex,
|
||||||
spaceport-nvim,
|
spaceport-nvim,
|
||||||
nomodoro,
|
nomodoro,
|
||||||
parrot-nvim,
|
# parrot-nvim,
|
||||||
inputs,
|
inputs,
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
@ -22,10 +22,10 @@ let
|
|||||||
name = "nomodoro";
|
name = "nomodoro";
|
||||||
};
|
};
|
||||||
|
|
||||||
parrotNvimPlugin = prev.vimUtils.buildVimPlugin {
|
# parrotNvimPlugin = prev.vimUtils.buildVimPlugin {
|
||||||
src = parrot-nvim;
|
# src = parrot-nvim;
|
||||||
name = "parrot-nvim";
|
# name = "parrot-nvim";
|
||||||
};
|
# };
|
||||||
|
|
||||||
nvimWebDeviconPlugin = prev.vimUtils.buildVimPlugin {
|
nvimWebDeviconPlugin = prev.vimUtils.buildVimPlugin {
|
||||||
src = inputs.nvim-web-devicons;
|
src = inputs.nvim-web-devicons;
|
||||||
@ -42,7 +42,7 @@ let
|
|||||||
cmp-vimtex = cmpVimtexPlugin;
|
cmp-vimtex = cmpVimtexPlugin;
|
||||||
spaceport-nvim = spaceportNvimPlugin;
|
spaceport-nvim = spaceportNvimPlugin;
|
||||||
nomodoro = nomodoroNvimPlugin;
|
nomodoro = nomodoroNvimPlugin;
|
||||||
parrot-nvim = parrotNvimPlugin;
|
# parrot-nvim = parrotNvimPlugin;
|
||||||
nvim-web-devicons = nvimWebDeviconPlugin;
|
nvim-web-devicons = nvimWebDeviconPlugin;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user