remove vscode folder

This commit is contained in:
d1nch8g
2026-04-17 00:17:32 +03:00
parent 7b041f6057
commit 76b736c1d9
3 changed files with 16 additions and 22 deletions
+1
View File
@@ -30,3 +30,4 @@ go.work.sum
# Editor/IDE
# .idea/
# .vscode/
-12
View File
@@ -1,12 +0,0 @@
{
"sqltools.connections": [
{
"ssh": "Disabled",
"previewLimit": 50,
"server": "localhost",
"driver": "PostgreSQL",
"connectString": "postgres://user:password@localhost:5432/db?sslmode=disable",
"name": "jules-local"
}
]
}
+15 -10
View File
@@ -3,6 +3,8 @@ package engine
import (
"errors"
"fmt"
"runtime"
"time"
"github.com/d1nch8g/jules/chat"
"github.com/d1nch8g/jules/database"
@@ -10,9 +12,14 @@ import (
"github.com/d1nch8g/jules/search"
)
const (
defaultActionPersistDuration = time.Hour * 72
defaultActionLimit = 120
)
type Parameters struct {
NumWorkers int
ActionLimit int
// Number of parallel workers running on the machine.
NumWorkers int
Database database.Database
LLM llm.LLM
@@ -21,10 +28,7 @@ type Parameters struct {
}
type Engine struct {
Database database.Database
LLM llm.LLM
Searcher search.Searcher
Chats map[string]chat.Chat
params *Parameters
}
func New(params *Parameters) (*Engine, error) {
@@ -32,6 +36,10 @@ func New(params *Parameters) (*Engine, error) {
return nil, errors.New("params can't be nil")
}
if params.NumWorkers == 0 {
params.NumWorkers = runtime.NumCPU()
}
if params.Database == nil {
return nil, errors.New("database can't be nil")
}
@@ -55,10 +63,7 @@ func New(params *Parameters) (*Engine, error) {
}
return &Engine{
Database: params.Database,
LLM: params.LLM,
Searcher: params.Searcher,
Chats: params.Chats,
params: params,
}, nil
}