Configuration System
Implement a hierarchical configuration system with .cora.yaml support.
Hierarchy (highest to lowest priority)
- CLI flags
- Environment variables (
CORA_MODEL, CORA_OUTPUT, etc.) - Project
.cora.yaml - User-level
~/.config/cora/config.yaml - Built-in defaults
Config File Schema (.cora.yaml)
provider:
name: openaiapi_key_env: OPENAI_API_KEYbase_url: https://api.openai.com/v1model: gpt-4otemperature: 0.1review:
severity: warninginclude: ["src/**/*.rs"]exclude: ["src/vendor/**"]language: enfocus: [security, performance, correctness, style]scan:
batch_size: 20chunk_lines: 500output:
format: prettycolor: auto
Requirements
- Parse YAML config using
serde_yaml - Merge configs across hierarchy levels
- Validate config values
cora init generates a starter .cora.yaml
Acceptance Criteria
Configuration System
Implement a hierarchical configuration system with
.cora.yamlsupport.Hierarchy (highest to lowest priority)
CORA_MODEL,CORA_OUTPUT, etc.).cora.yaml~/.config/cora/config.yamlConfig File Schema (
.cora.yaml)Requirements
serde_yamlcora initgenerates a starter.cora.yamlAcceptance Criteria
cora initcreates a documented template