Compose application and prompt configuration together

This commit is contained in:
2026-11-23 04:14:15 +00:00
parent 82c52c8e7f
commit f87c45331c
11 changed files with 338 additions and 151 deletions

View File

@@ -7,7 +7,7 @@ import (
"reflect"
"strings"
"gitea.maximumdirect.net/eric/audita/v4/internal/core/config"
"gitea.maximumdirect.net/eric/audita/v4/internal/appconfig"
"gitea.maximumdirect.net/eric/audita/v4/internal/framework/llm"
"gitea.maximumdirect.net/eric/audita/v4/internal/prompts"
"go.maximumdirect.net/ckconfig"
@@ -27,7 +27,7 @@ type engineEntry struct {
engine *pk.Engine
}
func loadApplication(ctx context.Context, selection ckconfig.Selection, _ struct{}, _ *invocationState) (*ck.Result[config.Config], error) {
func loadApplication(ctx context.Context, selection ckconfig.Selection, _ struct{}, _ *invocationState) (*ck.Result[appconfig.Config], error) {
if err := ctx.Err(); err != nil {
return nil, err
}
@@ -40,7 +40,7 @@ func loadApplication(ctx context.Context, selection ckconfig.Selection, _ struct
} else {
source = ck.SearchConfig("audita", ck.Searches(ck.WorkingDirectory(), ck.UserConfigDirectory(), ck.UnixSystemDirectories()))
}
return config.Load(ck.Input{Source: source}, selection.Overlay.Value, selection.Overrides...)
return appconfig.Load(ck.Input{Source: source}, selection.Overlay.Value, selection.Overrides...)
}
func loadPromptEngine(ctx context.Context, selection ckconfig.Selection, input struct{}, state *invocationState) (*pk.Engine, error) {