Implement InsertDataset and InsertMetadata in GO (#13883)

### What problem does this PR solve?

Implement InsertDataset and InsertMetadata in GO

new internal cli for go:

INSERT DATASET FROM FILE "file_name"
INSERT METADATA FROM FILE "file_name"

### Type of change

- [x] Refactoring
This commit is contained in:
qinling0210
2026-04-01 16:16:25 +08:00
committed by GitHub
parent b1d28b5898
commit bb4a06f759
18 changed files with 915 additions and 8 deletions

View File

@@ -166,6 +166,8 @@ func (p *Parser) parseUserCommand() (*Command, error) {
return p.parseGenerateCommand()
case TokenImport:
return p.parseImportCommand()
case TokenInsert:
return p.parseInsertCommand()
case TokenSearch:
return p.parseSearchCommand()
case TokenParse:
@@ -217,7 +219,7 @@ func (p *Parser) expectSemicolon() error {
}
func isKeyword(tokenType int) bool {
return tokenType >= TokenLogin && tokenType <= TokenDocMeta
return tokenType >= TokenLogin && tokenType <= TokenMetadata
}
// isCECommand checks if the given string is a ContextEngine command