summaryrefslogtreecommitdiff
path: root/schema
diff options
context:
space:
mode:
authorNate Sesti <sestinj@gmail.com>2023-07-22 22:37:13 -0700
committerNate Sesti <sestinj@gmail.com>2023-07-22 22:37:13 -0700
commit4d7e72970f770eb49627589fb142c93dfb6fd73b (patch)
tree7c85fb17a9e10ac8e387a001f021aa45c8c46582 /schema
parent007780d6d60095d4e0b238358ec26b2ec776b73e (diff)
downloadsncontinue-4d7e72970f770eb49627589fb142c93dfb6fd73b.tar.gz
sncontinue-4d7e72970f770eb49627589fb142c93dfb6fd73b.tar.bz2
sncontinue-4d7e72970f770eb49627589fb142c93dfb6fd73b.zip
@ feature (very large commit)
Diffstat (limited to 'schema')
-rw-r--r--schema/json/ContextItem.json76
-rw-r--r--schema/json/FullState.json132
2 files changed, 134 insertions, 74 deletions
diff --git a/schema/json/ContextItem.json b/schema/json/ContextItem.json
new file mode 100644
index 00000000..35766f11
--- /dev/null
+++ b/schema/json/ContextItem.json
@@ -0,0 +1,76 @@
+{
+ "title": "ContextItem",
+ "$ref": "#/definitions/src__continuedev__core__context__ContextItem",
+ "definitions": {
+ "ContextItemId": {
+ "title": "ContextItemId",
+ "description": "A ContextItemId is a unique identifier for a ContextItem.",
+ "type": "object",
+ "properties": {
+ "provider_title": {
+ "title": "Provider Title",
+ "type": "string"
+ },
+ "item_id": {
+ "title": "Item Id",
+ "type": "string"
+ }
+ },
+ "required": [
+ "provider_title",
+ "item_id"
+ ]
+ },
+ "ContextItemDescription": {
+ "title": "ContextItemDescription",
+ "description": "A ContextItemDescription is a description of a ContextItem that is displayed to the user when they type '@'.\n\nThe id can be used to retrieve the ContextItem from the ContextManager.",
+ "type": "object",
+ "properties": {
+ "name": {
+ "title": "Name",
+ "type": "string"
+ },
+ "description": {
+ "title": "Description",
+ "type": "string"
+ },
+ "id": {
+ "$ref": "#/definitions/ContextItemId"
+ }
+ },
+ "required": [
+ "name",
+ "description",
+ "id"
+ ]
+ },
+ "src__continuedev__core__context__ContextItem": {
+ "title": "ContextItem",
+ "description": "A ContextItem is a single item that is stored in the ContextManager.",
+ "type": "object",
+ "properties": {
+ "description": {
+ "$ref": "#/definitions/ContextItemDescription"
+ },
+ "content": {
+ "title": "Content",
+ "type": "string"
+ },
+ "editing": {
+ "title": "Editing",
+ "default": false,
+ "type": "boolean"
+ },
+ "editable": {
+ "title": "Editable",
+ "default": false,
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "description",
+ "content"
+ ]
+ }
+ }
+} \ No newline at end of file
diff --git a/schema/json/FullState.json b/schema/json/FullState.json
index 62ed337b..7b6dfd6b 100644
--- a/schema/json/FullState.json
+++ b/schema/json/FullState.json
@@ -157,108 +157,92 @@
"current_index"
]
},
- "Position": {
- "title": "Position",
+ "SlashCommandDescription": {
+ "title": "SlashCommandDescription",
"type": "object",
"properties": {
- "line": {
- "title": "Line",
- "type": "integer"
+ "name": {
+ "title": "Name",
+ "type": "string"
},
- "character": {
- "title": "Character",
- "type": "integer"
+ "description": {
+ "title": "Description",
+ "type": "string"
}
},
"required": [
- "line",
- "character"
+ "name",
+ "description"
]
},
- "Range": {
- "title": "Range",
- "description": "A range in a file. 0-indexed.",
+ "ContextItemId": {
+ "title": "ContextItemId",
+ "description": "A ContextItemId is a unique identifier for a ContextItem.",
"type": "object",
"properties": {
- "start": {
- "$ref": "#/definitions/Position"
+ "provider_title": {
+ "title": "Provider Title",
+ "type": "string"
},
- "end": {
- "$ref": "#/definitions/Position"
+ "item_id": {
+ "title": "Item Id",
+ "type": "string"
}
},
"required": [
- "start",
- "end"
+ "provider_title",
+ "item_id"
]
},
- "RangeInFileWithContents": {
- "title": "RangeInFileWithContents",
- "description": "A range in a file with the contents of the range.",
+ "ContextItemDescription": {
+ "title": "ContextItemDescription",
+ "description": "A ContextItemDescription is a description of a ContextItem that is displayed to the user when they type '@'.\n\nThe id can be used to retrieve the ContextItem from the ContextManager.",
"type": "object",
"properties": {
- "filepath": {
- "title": "Filepath",
+ "name": {
+ "title": "Name",
"type": "string"
},
- "range": {
- "$ref": "#/definitions/Range"
- },
- "contents": {
- "title": "Contents",
+ "description": {
+ "title": "Description",
"type": "string"
+ },
+ "id": {
+ "$ref": "#/definitions/ContextItemId"
}
},
"required": [
- "filepath",
- "range",
- "contents"
+ "name",
+ "description",
+ "id"
]
},
- "HighlightedRangeContext": {
- "title": "HighlightedRangeContext",
- "description": "Context for a highlighted range",
+ "ContextItem": {
+ "title": "ContextItem",
+ "description": "A ContextItem is a single item that is stored in the ContextManager.",
"type": "object",
"properties": {
- "range": {
- "$ref": "#/definitions/RangeInFileWithContents"
+ "description": {
+ "$ref": "#/definitions/ContextItemDescription"
+ },
+ "content": {
+ "title": "Content",
+ "type": "string"
},
"editing": {
"title": "Editing",
+ "default": false,
"type": "boolean"
},
- "pinned": {
- "title": "Pinned",
+ "editable": {
+ "title": "Editable",
+ "default": false,
"type": "boolean"
- },
- "display_name": {
- "title": "Display Name",
- "type": "string"
- }
- },
- "required": [
- "range",
- "editing",
- "pinned",
- "display_name"
- ]
- },
- "SlashCommandDescription": {
- "title": "SlashCommandDescription",
- "type": "object",
- "properties": {
- "name": {
- "title": "Name",
- "type": "string"
- },
- "description": {
- "title": "Description",
- "type": "string"
}
},
"required": [
- "name",
- "description"
+ "description",
+ "content"
]
},
"src__continuedev__core__main__FullState": {
@@ -284,13 +268,6 @@
"title": "Default Model",
"type": "string"
},
- "highlighted_ranges": {
- "title": "Highlighted Ranges",
- "type": "array",
- "items": {
- "$ref": "#/definitions/HighlightedRangeContext"
- }
- },
"slash_commands": {
"title": "Slash Commands",
"type": "array",
@@ -301,6 +278,13 @@
"adding_highlighted_code": {
"title": "Adding Highlighted Code",
"type": "boolean"
+ },
+ "selected_context_items": {
+ "title": "Selected Context Items",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/ContextItem"
+ }
}
},
"required": [
@@ -308,9 +292,9 @@
"active",
"user_input_queue",
"default_model",
- "highlighted_ranges",
"slash_commands",
- "adding_highlighted_code"
+ "adding_highlighted_code",
+ "selected_context_items"
]
}
}