mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-03-05 23:57:13 +08:00
# RAGFlow Go Implementation Plan 🚀 This repository tracks the progress of porting RAGFlow to Go. We'll implement core features and provide performance comparisons between Python and Go versions. ## Implementation Checklist - [x] User Management APIs - [x] Dataset Management Operations - [x] Retrieval Test - [x] Chat Management Operations - [x] Infinity Go SDK --------- Signed-off-by: Jin Hai <haijin.chn@gmail.com> Co-authored-by: Yingfeng Zhang <yingfeng.zhang@gmail.com>
35 lines
526 B
Go
35 lines
526 B
Go
package main
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
"os/signal"
|
|
"syscall"
|
|
|
|
"ragflow/internal/cli"
|
|
)
|
|
|
|
func main() {
|
|
// Create CLI instance
|
|
cliApp, err := cli.NewCLI()
|
|
if err != nil {
|
|
fmt.Printf("Failed to create CLI: %v\n", err)
|
|
os.Exit(1)
|
|
}
|
|
|
|
// Handle interrupt signal
|
|
sigChan := make(chan os.Signal, 1)
|
|
signal.Notify(sigChan, syscall.SIGINT, syscall.SIGTERM)
|
|
go func() {
|
|
<-sigChan
|
|
cliApp.Cleanup()
|
|
os.Exit(0)
|
|
}()
|
|
|
|
// Run CLI
|
|
if err := cliApp.Run(); err != nil {
|
|
fmt.Printf("CLI error: %v\n", err)
|
|
os.Exit(1)
|
|
}
|
|
}
|