-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwhygraph.example.toml
More file actions
89 lines (77 loc) · 4.32 KB
/
Copy pathwhygraph.example.toml
File metadata and controls
89 lines (77 loc) · 4.32 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
# WhyGraph configuration — whygraph.toml
#
# Scaffolded by `whygraph init`. Every field is optional and the values shown
# are the built-in defaults, so an unedited file behaves exactly as if no
# config were present. Uncomment and edit to override.
log_level = "INFO" # DEBUG | INFO | WARN | ERROR | CRITICAL
[scan]
max_workers = 2 # parallel LLM calls in the diff-analyzer crawler
provider = "off" # source-control backend for the PR/issue crawl:
# "off" — skip remote crawl (default)
# "github" — pull PRs/issues from the GitHub remote
# "auto" — detect from the remote URL (github only, for now)
remote = "origin" # git remote whose URL is inspected for provider/auto
# token = "ghp_..." # GitHub token for the gh CLI during the remote crawl.
# Default: read GH_TOKEN / GITHUB_TOKEN from env (or an
# existing `gh auth login`). Set here to pin a per-project
# token — handy when one shared container scans repos
# across different orgs. whygraph.toml is gitignored, so a
# token here is never committed.
[analyze]
# LLM that writes a per-commit "git diff" description during `whygraph scan`.
provider = "anthropic" # which [llm.*] adapter to use
# model = "claude-haiku-4-5" # override the provider's model for analysis only
# max_diff_chars = 50000 # diff truncated past this length before prompting
# large_commit_file_count = 30 # commits touching more files than this are described
# per-file on demand (not whole-diff) — keeps a bulk
# import / squash commit from costing a repo-wide pass
# pr_origin_min_commits = 5 # recover a squash-merged PR's original commits once it
# collapsed >= this many (file-bulk squashes recover too)
# timeout_sec = 60 # per-call timeout; default: the adapter's own
[rationale]
# LLM that writes a structured "why this code exists" rationale card.
provider = "anthropic" # which [llm.*] adapter to use
# model = "claude-haiku-4-5" # override the provider's model for rationale only
# timeout_sec = 60 # per-call timeout; default: the adapter's own
# Caps on how much of a squash-merged PR is rendered into the rationale prompt
# (the raw whygraph_evidence_for tool output is uncapped):
# pr_roster_max_commits = 30 # squashed-commit headlines shown per PR
# pr_discussion_max_comments = 20 # PR comments shown per PR
# pr_comment_max_chars = 500 # each PR comment clipped to this length
# Uncomment to override default DB locations (resolved relative to this file):
# whygraph_db = ".whygraph/whygraph.db"
# codegraph_db = ".codegraph/codegraph.db"
# Optional rotating file log. Console (stderr) logging is always on. Uncomment
# this section to add an *additional* file handler; leave it out (or leave
# `file` unset) to keep file logging off.
# [logging]
# file = ".whygraph/logs/whygraph.log" # resolved relative to this file
# level = "DEBUG" # default: inherit top-level log_level
# max_bytes = 5_000_000
# backup_count = 3
# Per-provider LLM client settings. Each table is consumed by the matching
# adapter in whygraph.services.llm via Adapter.from_config. Omit api_key to
# read the standard env var (ANTHROPIC_API_KEY, OPENAI_API_KEY,
# DEEPSEEK_API_KEY); omit a section entirely to use the defaults shown.
[llm.anthropic]
model = "claude-opus-4-7"
# api_key = "sk-ant-..." # default: read ANTHROPIC_API_KEY from env
timeout_sec = 60
[llm.openai]
model = "gpt-4o"
# api_key = "sk-..." # default: read OPENAI_API_KEY from env
# base_url = "..." # default: https://api.openai.com/v1
timeout_sec = 60
[llm.deepseek]
model = "deepseek-chat"
# api_key = "sk-..." # default: read DEEPSEEK_API_KEY from env
timeout_sec = 60
[llm.ollama]
model = "llama3"
# host = "http://localhost:11434"
timeout_sec = 120
# `claude_cli` (Python attribute) and `claude-cli` (TOML idiom) both parse.
[llm.claude_cli]
model = "claude-opus-4-7"
# api_key = "sk-ant-..." # default: subscription billing (strips env var)
timeout_sec = 120