chore: better welcome messgae, throw on config parse error
add instructions for gateway mode, change config order, and don't hard-code the config path, pull it from the default config
This commit is contained in:
@@ -112,6 +112,7 @@ export type HeartbeatConfig = z.infer<typeof HeartbeatConfigSchema>;
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export const ConfigSchema = z.object({
|
||||
providers: ProvidersConfigSchema.default(() => ({})),
|
||||
agent: AgentConfigSchema.default(() => ({
|
||||
model: 'anthropic/claude-sonnet-4-5',
|
||||
workspacePath: '~/.config/nanobot',
|
||||
@@ -120,13 +121,12 @@ export const ConfigSchema = z.object({
|
||||
temperature: 0.7,
|
||||
maxToolIterations: 40,
|
||||
})),
|
||||
providers: ProvidersConfigSchema.default(() => ({})),
|
||||
heartbeat: HeartbeatConfigSchema.default(() => ({ enabled: false, intervalMinutes: 30 })),
|
||||
channels: ChannelsConfigSchema.default(() => ({ sendProgress: true, sendToolHints: true })),
|
||||
tools: ToolsConfigSchema.default(() => ({
|
||||
exec: { timeout: 120, denyPatterns: [], restrictToWorkspace: false },
|
||||
web: {},
|
||||
restrictToWorkspace: false,
|
||||
})),
|
||||
heartbeat: HeartbeatConfigSchema.default(() => ({ enabled: false, intervalMinutes: 30 })),
|
||||
});
|
||||
export type Config = z.infer<typeof ConfigSchema>;
|
||||
|
||||
Reference in New Issue
Block a user