diff --git a/gen/api/ResourceAPI.pkl.go b/gen/api/ResourceHTTPClient.pkl.go similarity index 69% rename from gen/api/ResourceAPI.pkl.go rename to gen/api/ResourceHTTPClient.pkl.go index f2e90d8..efda44e 100644 --- a/gen/api/ResourceAPI.pkl.go +++ b/gen/api/ResourceHTTPClient.pkl.go @@ -1,7 +1,7 @@ // Code generated from Pkl module `org.kdeps.pkl.API`. DO NOT EDIT. package api -type ResourceAPI struct { +type ResourceHTTPClient struct { Method string `pkl:"method"` Url string `pkl:"url"` @@ -10,5 +10,5 @@ type ResourceAPI struct { Output *string `pkl:"output"` - Headers []*ResourceAPIHeaders `pkl:"headers"` + Headers []*ResourceHTTPClientHeaders `pkl:"headers"` } diff --git a/gen/api/ResourceAPIHeaders.pkl.go b/gen/api/ResourceHTTPClientHeaders.pkl.go similarity index 77% rename from gen/api/ResourceAPIHeaders.pkl.go rename to gen/api/ResourceHTTPClientHeaders.pkl.go index 4b52d55..48563ac 100644 --- a/gen/api/ResourceAPIHeaders.pkl.go +++ b/gen/api/ResourceHTTPClientHeaders.pkl.go @@ -1,7 +1,7 @@ // Code generated from Pkl module `org.kdeps.pkl.API`. DO NOT EDIT. package api -type ResourceAPIHeaders struct { +type ResourceHTTPClientHeaders struct { Name string `pkl:"name"` Value string `pkl:"value"` diff --git a/gen/api/init.pkl.go b/gen/api/init.pkl.go index 5837bef..a8351ec 100644 --- a/gen/api/init.pkl.go +++ b/gen/api/init.pkl.go @@ -7,6 +7,6 @@ func init() { pkl.RegisterMapping("org.kdeps.pkl.API#APIServerSettings", APIServerSettings{}) pkl.RegisterMapping("org.kdeps.pkl.API#APIServerRoutes", APIServerRoutes{}) pkl.RegisterMapping("org.kdeps.pkl.API", API{}) - pkl.RegisterMapping("org.kdeps.pkl.API#ResourceAPI", ResourceAPI{}) - pkl.RegisterMapping("org.kdeps.pkl.API#ResourceAPIHeaders", ResourceAPIHeaders{}) + pkl.RegisterMapping("org.kdeps.pkl.API#ResourceHTTPClient", ResourceHTTPClient{}) + pkl.RegisterMapping("org.kdeps.pkl.API#ResourceHTTPClientHeaders", ResourceHTTPClientHeaders{}) } diff --git a/gen/env/ResourceEnv.pkl.go b/gen/env/ResourceEnv.pkl.go index 8a9eb14..811d7e0 100644 --- a/gen/env/ResourceEnv.pkl.go +++ b/gen/env/ResourceEnv.pkl.go @@ -7,6 +7,4 @@ type ResourceEnv struct { Exec *string `pkl:"exec"` Value *string `pkl:"value"` - - Input *string `pkl:"input"` } diff --git a/gen/llm/LLMSettings.pkl.go b/gen/llm/LLMSettings.pkl.go index ebd8759..056cea9 100644 --- a/gen/llm/LLMSettings.pkl.go +++ b/gen/llm/LLMSettings.pkl.go @@ -9,6 +9,4 @@ type LLMSettings struct { LlmFallbackBackend llmbackend.LLMBackend `pkl:"llmFallbackBackend"` LlmFallbackModel string `pkl:"llmFallbackModel"` - - ModelFile *ModelFile `pkl:"modelFile"` } diff --git a/gen/llm/ModelFile.pkl.go b/gen/llm/ModelFile.pkl.go deleted file mode 100644 index dd92892..0000000 --- a/gen/llm/ModelFile.pkl.go +++ /dev/null @@ -1,14 +0,0 @@ -// Code generated from Pkl module `org.kdeps.pkl.LLM`. DO NOT EDIT. -package llm - -type ModelFile struct { - Name string `pkl:"name"` - - From string `pkl:"from"` - - Parameter *Parameter `pkl:"parameter"` - - Template string `pkl:"template"` - - Stop []string `pkl:"stop"` -} diff --git a/gen/llm/Parameter.pkl.go b/gen/llm/Parameter.pkl.go deleted file mode 100644 index b87c5cd..0000000 --- a/gen/llm/Parameter.pkl.go +++ /dev/null @@ -1,30 +0,0 @@ -// Code generated from Pkl module `org.kdeps.pkl.LLM`. DO NOT EDIT. -package llm - -type Parameter struct { - Mirostat int `pkl:"mirostat"` - - MirostatEta float64 `pkl:"mirostat_eta"` - - MirostatTau float64 `pkl:"mirostat_tau"` - - NumCtx int `pkl:"num_ctx"` - - RepeatLastN int `pkl:"repeat_last_n"` - - RepeatPenalty float64 `pkl:"repeat_penalty"` - - Temperature float64 `pkl:"temperature"` - - Seed int `pkl:"seed"` - - TfsZ float64 `pkl:"tfs_z"` - - NumPredict int `pkl:"num_predict"` - - TopK int `pkl:"top_k"` - - TopP float64 `pkl:"top_p"` - - MinP float64 `pkl:"min_p"` -} diff --git a/gen/llm/ResourceChatSchema.pkl.go b/gen/llm/ResourceChatSchema.pkl.go deleted file mode 100644 index 89731e3..0000000 --- a/gen/llm/ResourceChatSchema.pkl.go +++ /dev/null @@ -1,18 +0,0 @@ -// Code generated from Pkl module `org.kdeps.pkl.LLM`. DO NOT EDIT. -package llm - -import "github.com/kdeps/schema/gen/llm/llmbackend" - -type ResourceChatSchema struct { - Backend llmbackend.LLMBackend `pkl:"backend"` - - Model string `pkl:"model"` - - Prompt string `pkl:"prompt"` - - Schema string `pkl:"schema"` - - Input *string `pkl:"input"` - - Output string `pkl:"output"` -} diff --git a/gen/llm/init.pkl.go b/gen/llm/init.pkl.go index c2fa344..dc79451 100644 --- a/gen/llm/init.pkl.go +++ b/gen/llm/init.pkl.go @@ -7,8 +7,5 @@ func init() { pkl.RegisterMapping("org.kdeps.pkl.LLM#LLMSettings", LLMSettings{}) pkl.RegisterMapping("org.kdeps.pkl.LLM#LLMAPIKeys", LLMAPIKeys{}) pkl.RegisterMapping("org.kdeps.pkl.LLM", LLM{}) - pkl.RegisterMapping("org.kdeps.pkl.LLM#Parameter", Parameter{}) - pkl.RegisterMapping("org.kdeps.pkl.LLM#ModelFile", ModelFile{}) pkl.RegisterMapping("org.kdeps.pkl.LLM#ResourceChat", ResourceChat{}) - pkl.RegisterMapping("org.kdeps.pkl.LLM#ResourceChatSchema", ResourceChatSchema{}) } diff --git a/gen/llm/llmbackend/LLMBackend.pkl.go b/gen/llm/llmbackend/LLMBackend.pkl.go index 79c7848..ce44b08 100644 --- a/gen/llm/llmbackend/LLMBackend.pkl.go +++ b/gen/llm/llmbackend/LLMBackend.pkl.go @@ -9,11 +9,11 @@ import ( type LLMBackend string const ( - Ollama LLMBackend = "ollama" - Openai LLMBackend = "openai" - Mistral LLMBackend = "mistral" - Huggingface LLMBackend = "huggingface" - Groq LLMBackend = "groq" + Local LLMBackend = "local" + OpenaiApi LLMBackend = "openai-api" + MistralApi LLMBackend = "mistral-api" + HuggingfaceApi LLMBackend = "huggingface-api" + GroqApi LLMBackend = "groq-api" ) // String returns the string representation of LLMBackend @@ -26,16 +26,16 @@ var _ encoding.BinaryUnmarshaler = new(LLMBackend) // UnmarshalBinary implements encoding.BinaryUnmarshaler for LLMBackend. func (rcv *LLMBackend) UnmarshalBinary(data []byte) error { switch str := string(data); str { - case "ollama": - *rcv = Ollama - case "openai": - *rcv = Openai - case "mistral": - *rcv = Mistral - case "huggingface": - *rcv = Huggingface - case "groq": - *rcv = Groq + case "local": + *rcv = Local + case "openai-api": + *rcv = OpenaiApi + case "mistral-api": + *rcv = MistralApi + case "huggingface-api": + *rcv = HuggingfaceApi + case "groq-api": + *rcv = GroqApi default: return fmt.Errorf(`illegal: "%s" is not a valid LLMBackend`, str) } diff --git a/gen/resource/RAGAction.pkl.go b/gen/resource/RAGAction.pkl.go deleted file mode 100644 index 4440d9c..0000000 --- a/gen/resource/RAGAction.pkl.go +++ /dev/null @@ -1,5 +0,0 @@ -// Code generated from Pkl module `org.kdeps.pkl.Resource`. DO NOT EDIT. -package resource - -type RAGAction struct { -} diff --git a/gen/resource/RAGResource.pkl.go b/gen/resource/RAGResource.pkl.go deleted file mode 100644 index ac4d14a..0000000 --- a/gen/resource/RAGResource.pkl.go +++ /dev/null @@ -1,16 +0,0 @@ -// Code generated from Pkl module `org.kdeps.pkl.Resource`. DO NOT EDIT. -package resource - -type RAGResource struct { - Id string `pkl:"id"` - - Name string `pkl:"name"` - - Description string `pkl:"description"` - - Category string `pkl:"category"` - - Requires *[]string `pkl:"requires"` - - Action *[]*RAGAction `pkl:"action"` -} diff --git a/gen/resource/Resource.pkl.go b/gen/resource/Resource.pkl.go index dff6ae6..ede897d 100644 --- a/gen/resource/Resource.pkl.go +++ b/gen/resource/Resource.pkl.go @@ -9,8 +9,6 @@ import ( type Resource struct { Resources []*AppResource `pkl:"resources"` - - Rag []*RAGResource `pkl:"rag"` } // LoadFromPath loads the pkl module at the given path and evaluates it into a Resource diff --git a/gen/resource/ResourceAction.pkl.go b/gen/resource/ResourceAction.pkl.go index 6414e2d..0c3284b 100644 --- a/gen/resource/ResourceAction.pkl.go +++ b/gen/resource/ResourceAction.pkl.go @@ -17,15 +17,11 @@ type ResourceAction struct { Skip *[]string `pkl:"skip"` - Check *[]string `pkl:"check"` - - Expect *[]string `pkl:"expect"` + Preflight *[]string `pkl:"preflight"` Env *[]*env.ResourceEnv `pkl:"env"` Chat *[]*llm.ResourceChat `pkl:"chat"` - Schat *[]*llm.ResourceChatSchema `pkl:"schat"` - - Api *[]*api.ResourceAPI `pkl:"api"` + HttpClient *[]*api.ResourceHTTPClient `pkl:"httpClient"` } diff --git a/gen/resource/init.pkl.go b/gen/resource/init.pkl.go index d205680..c03a6f4 100644 --- a/gen/resource/init.pkl.go +++ b/gen/resource/init.pkl.go @@ -7,6 +7,4 @@ func init() { pkl.RegisterMapping("org.kdeps.pkl.Resource", Resource{}) pkl.RegisterMapping("org.kdeps.pkl.Resource#AppResource", AppResource{}) pkl.RegisterMapping("org.kdeps.pkl.Resource#ResourceAction", ResourceAction{}) - pkl.RegisterMapping("org.kdeps.pkl.Resource#RAGResource", RAGResource{}) - pkl.RegisterMapping("org.kdeps.pkl.Resource#RAGAction", RAGAction{}) }