remove /code_action
This commit is contained in:
parent
3ea13376cc
commit
829be553ee
@ -38,7 +38,6 @@ You can configure the following settings in your `settings.json` file:
|
|||||||
|
|
||||||
- `DevChat.llmModel`: Select the AI model to use (default: "OpenAI").
|
- `DevChat.llmModel`: Select the AI model to use (default: "OpenAI").
|
||||||
- `DevChat.maxLogCount`: Limit the number of prompts to output (default: 20).
|
- `DevChat.maxLogCount`: Limit the number of prompts to output (default: 20).
|
||||||
- `DevChat.logSkip`: Skip a number of prompts before showing the prompt history (default: 0).
|
|
||||||
- `DevChat.OpenAI.model`: Specify the AI model (default: "gpt-4").
|
- `DevChat.OpenAI.model`: Specify the AI model (default: "gpt-4").
|
||||||
- `DevChat.OpenAI.temperature`: Specify the AI model temperature (default: 0.2).
|
- `DevChat.OpenAI.temperature`: Specify the AI model temperature (default: 0.2).
|
||||||
- `DevChat.OpenAI.stream`: Specify the AI model stream (default: true).
|
- `DevChat.OpenAI.stream`: Specify the AI model stream (default: true).
|
||||||
|
@ -135,14 +135,14 @@ class DevChat {
|
|||||||
const openaiStream = vscode.workspace.getConfiguration('DevChat').get('OpenAI.stream');
|
const openaiStream = vscode.workspace.getConfiguration('DevChat').get('OpenAI.stream');
|
||||||
const llmModel = vscode.workspace.getConfiguration('DevChat').get('llmModel');
|
const llmModel = vscode.workspace.getConfiguration('DevChat').get('llmModel');
|
||||||
const tokensPerPrompt = vscode.workspace.getConfiguration('DevChat').get('OpenAI.tokensPerPrompt');
|
const tokensPerPrompt = vscode.workspace.getConfiguration('DevChat').get('OpenAI.tokensPerPrompt');
|
||||||
const userHistoryPrompts = vscode.workspace.getConfiguration('DevChat').get('OpenAI.useHistoryPrompt');
|
// const userHistoryPrompts = vscode.workspace.getConfiguration('DevChat').get('OpenAI.useHistoryPrompt');
|
||||||
|
|
||||||
let devChat : string|undefined = vscode.workspace.getConfiguration('DevChat').get('DevChatPath');
|
let devChat : string|undefined = vscode.workspace.getConfiguration('DevChat').get('DevChatPath');
|
||||||
if (!devChat) {
|
if (!devChat) {
|
||||||
devChat = 'devchat';
|
devChat = 'devchat';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (userHistoryPrompts && options.parent) {
|
if (options.parent) {
|
||||||
args.push("-p", options.parent);
|
args.push("-p", options.parent);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -261,8 +261,8 @@ class DevChat {
|
|||||||
if (options.skip) {
|
if (options.skip) {
|
||||||
args.push('--skip', `${options.skip}`);
|
args.push('--skip', `${options.skip}`);
|
||||||
} else {
|
} else {
|
||||||
const skipLogCount = vscode.workspace.getConfiguration('DevChat').get('logSkip');
|
// const skipLogCount = vscode.workspace.getConfiguration('DevChat').get('logSkip');
|
||||||
args.push('--skip', `${skipLogCount}`);
|
// args.push('--skip', `${skipLogCount}`);
|
||||||
}
|
}
|
||||||
if (options.maxCount) {
|
if (options.maxCount) {
|
||||||
args.push('--max-count', `${options.maxCount}`);
|
args.push('--max-count', `${options.maxCount}`);
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"pattern": "code",
|
"pattern": "code",
|
||||||
"description": "work for generate code",
|
"description": "write code (default)",
|
||||||
"message": "",
|
"message": "",
|
||||||
"default": false,
|
"default": true,
|
||||||
"instructions": ["instruct.txt", "python.txt"]
|
"instructions": ["instruct.txt", "python.txt"]
|
||||||
}
|
}
|
@ -1,7 +0,0 @@
|
|||||||
{
|
|
||||||
"pattern": "code_actions",
|
|
||||||
"description": "work for generate code",
|
|
||||||
"message": "",
|
|
||||||
"default": true,
|
|
||||||
"instructions": ["instruct.txt", "python.txt"]
|
|
||||||
}
|
|
@ -1,24 +0,0 @@
|
|||||||
As a software developer assistant, your tasks are to:
|
|
||||||
|
|
||||||
- Provide a clear and concise response to address the user's requirements.
|
|
||||||
- Write code and give advice based on given code or information in the <context> if provided.
|
|
||||||
- Follow language-specific best practices and common coding standards.
|
|
||||||
|
|
||||||
When responding:
|
|
||||||
|
|
||||||
1. Summarize and describe the requirements or provided information in your own words.
|
|
||||||
2. The summary and description should better be written in bullet points (excluding code).
|
|
||||||
3. When modifying the provided code, include the entire modified functions, but exclude any unmodified functions.
|
|
||||||
If any global statements are changed, include the full global statements; otherwise, do not include them.
|
|
||||||
4. Enclose code or changes within blocks using triple backticks (```), and include the programming language and the file path, if available. For example:
|
|
||||||
```
|
|
||||||
```python path=./path/to/file.py
|
|
||||||
print("Hello, World!")
|
|
||||||
```
|
|
||||||
```
|
|
||||||
If no file paths or folder structure are provided and you are unsure about the file path of the code, you may omit the file path.
|
|
||||||
5. Use separate code blocks for different files.
|
|
||||||
6. Utilize the previous messages, if provided in the end of this prompt, to create your response. Note that not all previous messages are necessarily relevant.
|
|
||||||
7. When providing a suggestion or instruction, begin by explaining the reason behind it.
|
|
||||||
8. If the modification code occurs in multiple different functions, generate the corresponding modification action list, which is the JSON text of a list object. There are three types of actions, "delete", "insert", and "modify". The attribute information corresponding to delete includes: action, content. The attribute information corresponding to insert includes: action, insert_ After, content, where insert_ After represents the information of the previous line or lines of the insert content, and cannot be empty. If it is empty, the search will continue forward. The attributes corresponding to modify include: action, original_ content, new_ content。 JSON text is marked as a markup code block.
|
|
||||||
9. If you need more information, ask for it.
|
|
@ -1 +0,0 @@
|
|||||||
When writing Python code, include type hints where appropriate and maintain compliance with PEP-8 guidelines, such as providing docstrings for modules, classes, and functions.
|
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"pattern": "commit_message",
|
"pattern": "commit_message",
|
||||||
"description": "generate commit message",
|
"description": "write a commit message",
|
||||||
"message": "write a commit message",
|
"message": "write a commit message",
|
||||||
"default": false,
|
"default": false,
|
||||||
"instructions": ["instruct.txt"]
|
"instructions": ["instruct.txt"]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user