Merge branch 'main' of https://github.com/continuedev/continue
This commit is contained in:
commit
00ffcc7795
6 changed files with 14 additions and 46 deletions
|
|
@ -27,37 +27,21 @@ class ContinueConfig(BaseModel):
|
|||
# description="Write pytest unit tests for the current file",
|
||||
# step_name="WritePytestsRecipe",
|
||||
# params=??)
|
||||
|
||||
SlashCommand(
|
||||
name="dlt",
|
||||
description="Create a dlt pipeline",
|
||||
step_name="CreatePipelineRecipe",
|
||||
name="edit",
|
||||
description="Edit code in the current file or the highlighted code",
|
||||
step_name="EditHighlightedCodeStep",
|
||||
),
|
||||
SlashCommand(
|
||||
name="ddtobq",
|
||||
description="Adjust a dlt pipeline to load data into BigQuery",
|
||||
step_name="DDtoBQRecipe",
|
||||
),
|
||||
SlashCommand(
|
||||
name="addtransform",
|
||||
description="Add transforms to the chess.com API dlt pipeline.",
|
||||
step_name="AddTransformRecipe",
|
||||
),
|
||||
SlashCommand(
|
||||
name="deployairflow",
|
||||
description="Deploy a dlt pipeline to Airflow",
|
||||
step_name="DeployPipelineAirflowRecipe",
|
||||
name="explain",
|
||||
description="Reply to instructions or a question with previous steps as context",
|
||||
step_name="SimpleChatStep",
|
||||
),
|
||||
SlashCommand(
|
||||
name="comment",
|
||||
description="Write comments for the current file or highlighted code",
|
||||
step_name="CommentCodeStep",
|
||||
),
|
||||
SlashCommand(
|
||||
name="pytest",
|
||||
description="Write pytest unit tests for the current file",
|
||||
step_name="WritePytestsRecipe",
|
||||
),
|
||||
SlashCommand(
|
||||
name="feedback",
|
||||
description="Send feedback to improve Continue",
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ class DemoPolicy(Policy):
|
|||
# At the very start, run initial Steps spcecified in the config
|
||||
if history.get_current() is None:
|
||||
return (
|
||||
MessageStep(name="Welcome to Continue!", message="You can type a question or instructions for a file edit in the text box. If you highlight code, edits will be localized to the highlighted range. Otherwise, the currently open file is taken as context. If you type '/', you can see the list of available slash commands.") >>
|
||||
MessageStep(name="Welcome to Continue!", message="Type '/' to see the list of available slash commands. If you highlight code, edits and explanations will be localized to the highlighted range. Otherwise, the currently open file is used. In both cases, the code is combined with the previous steps to construct the context.") >>
|
||||
# SetupContinueWorkspaceStep() >>
|
||||
# CreateCodebaseIndexChroma() >>
|
||||
StepsOnStartupStep())
|
||||
|
|
@ -45,12 +45,6 @@ class DemoPolicy(Policy):
|
|||
params["user_input"] = after_command
|
||||
return get_step_from_name(slash_command.step_name, params)
|
||||
|
||||
if "/ask" in user_input:
|
||||
return AnswerQuestionChroma(question=" ".join(user_input.split(" ")[1:]))
|
||||
elif "/edit" in user_input:
|
||||
return EditFileChroma(request=" ".join(user_input.split(" ")[1:]))
|
||||
elif "/step" in user_input:
|
||||
return ContinueStepStep(prompt=" ".join(user_input.split(" ")[1:]))
|
||||
# return EditHighlightedCodeStep(user_input=user_input)
|
||||
return NLDecisionStep(user_input=user_input, steps=[
|
||||
(EditHighlightedCodeStep(user_input=user_input),
|
||||
|
|
|
|||
|
|
@ -2,23 +2,15 @@ from typing import Dict
|
|||
|
||||
from ...core.main import Step
|
||||
from ...steps.core.core import UserInputStep
|
||||
from ...recipes.CreatePipelineRecipe.main import CreatePipelineRecipe
|
||||
from ...recipes.DDtoBQRecipe.main import DDtoBQRecipe
|
||||
from ...recipes.DeployPipelineAirflowRecipe.main import DeployPipelineAirflowRecipe
|
||||
from ...recipes.DDtoBQRecipe.main import DDtoBQRecipe
|
||||
from ...recipes.AddTransformRecipe.main import AddTransformRecipe
|
||||
from ...recipes.WritePytestsRecipe.main import WritePytestsRecipe
|
||||
from ...steps.main import EditHighlightedCodeStep
|
||||
from ...steps.chat import SimpleChatStep
|
||||
from ...steps.comment_code import CommentCodeStep
|
||||
from ...steps.feedback import FeedbackStep
|
||||
|
||||
step_name_to_step_class = {
|
||||
"UserInputStep": UserInputStep,
|
||||
"CreatePipelineRecipe": CreatePipelineRecipe,
|
||||
"DDtoBQRecipe": DDtoBQRecipe,
|
||||
"DeployPipelineAirflowRecipe": DeployPipelineAirflowRecipe,
|
||||
"AddTransformRecipe": AddTransformRecipe,
|
||||
"DDtoBQRecipe": DDtoBQRecipe,
|
||||
"WritePytestsRecipe": WritePytestsRecipe,
|
||||
"EditHighlightedCodeStep": EditHighlightedCodeStep,
|
||||
"SimpleChatStep": SimpleChatStep,
|
||||
"CommentCodeStep": CommentCodeStep,
|
||||
"FeedbackStep": FeedbackStep,
|
||||
}
|
||||
|
|
@ -30,4 +22,4 @@ def get_step_from_name(step_name: str, params: Dict) -> Step:
|
|||
except:
|
||||
print(
|
||||
f"Incorrect parameters for step {step_name}. Parameters provided were: {params}")
|
||||
raise
|
||||
raise
|
||||
|
|
@ -111,7 +111,6 @@
|
|||
"clientgen": "rm -rf src/client/ && npx @openapitools/openapi-generator-cli generate -i ../schema/openapi.json -g typescript-fetch -o src/client/ --additional-properties=supportsES6=true,npmVersion=8.19.2,typescriptThreePlus=true",
|
||||
"typegen": "node scripts/typegen.js",
|
||||
"rebuild": "electron-rebuild -v 19.1.8 node-pty",
|
||||
"compile": "tsc -p ./",
|
||||
"watch": "tsc -watch -p ./",
|
||||
"pretest": "npm run compile && npm run lint",
|
||||
"lint": "eslint src --ext ts",
|
||||
|
|
|
|||
|
|
@ -105,7 +105,7 @@ const ComboBox = React.forwardRef((props: ComboBoxProps, ref) => {
|
|||
<div className="flex px-2" ref={divRef} hidden={!isOpen}>
|
||||
<MainTextInput
|
||||
disabled={props.disabled}
|
||||
placeholder="Type instructions or a question. Highlighted code / the open file are used as context."
|
||||
placeholder="Type '/' to see the list of available slash commands..."
|
||||
{...getInputProps({
|
||||
onKeyDown: (event) => {
|
||||
if (event.key === "Enter" && (!isOpen || items.length === 0)) {
|
||||
|
|
|
|||
|
|
@ -20,9 +20,8 @@
|
|||
|
||||
9. `cmd+shift+p` to look at developer console and select Continue commands
|
||||
|
||||
10. Every time you make changes to the code, you need to run `npm run compile`
|
||||
10. Every time you make changes to the code, you need to run `npm run esbuild` unless you make changes inside of `react-app` and then you need to run `npm run build` from there
|
||||
|
||||
11. If you run into a "command not found" error, try running `npm run rebuild` and then `npm run compile`
|
||||
|
||||
## Alternative: Install from source
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue