complexity router : add complexity analyzer config DB and API changes - #3712
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughAdds persisted, normalized ComplexityAnalyzerConfig (tier boundaries + keywords), schema definitions, RDB persistence and ConfigStore APIs, plugin defaults and matcher parameterization, atomic runtime reload with a ReloadComplexityAnalyzerConfig API, HTTP GET/PUT/POST endpoints, and tests syncing file, store, and runtime state. ChangesComplexity Analyzer Runtime Configuration
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 1 | ❌ 4❌ Failed checks (3 warnings, 1 inconclusive)
✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@framework/configstore/rdb.go`:
- Around line 4208-4214: In GetGovernanceConfig (the switch handling
tables.ConfigComplexityAnalyzerConfigKey) skip DecodeComplexityAnalyzerConfig
when entry.Value is empty/zero-length and treat it as unset: check if
entry.Value == "" (or len(entry.Value) == 0) before calling
DecodeComplexityAnalyzerConfig, and if empty simply continue without logging a
warning; otherwise call DecodeComplexityAnalyzerConfig and keep the existing
error handling that logs via s.logger.Warn. Ensure you reference
tables.ConfigComplexityAnalyzerConfigKey and DecodeComplexityAnalyzerConfig in
the change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: f5124ad4-95ed-4c76-b054-c7e960035454
📒 Files selected for processing (17)
framework/configstore/clientconfig.goframework/configstore/complexityconfig.goframework/configstore/rdb.goframework/configstore/rdb_test.goframework/configstore/store.goframework/configstore/tables/config.goplugins/governance/complexity/analyzer.goplugins/governance/complexity/analyzer_test.goplugins/governance/complexity/config.goplugins/governance/complexity/matcher.goplugins/governance/main.gotransports/bifrost-http/handlers/governance.gotransports/bifrost-http/handlers/governance_test.gotransports/bifrost-http/lib/config.gotransports/bifrost-http/lib/config_test.gotransports/bifrost-http/server/server.gotransports/config.schema.json
Confidence Score: 5/5Safe to merge; the concurrency model, validation pipeline, and HTTP handler flow are all correct. The atomic swap of the analyzer pointer is correct, validation runs before every DB write, the HTTP handler chain (validate → persist → reload) is properly ordered, and the config file merge path is consistent with existing governance patterns. Test coverage is thorough across the DB, handler, and analyzer layers. plugins/governance/complexity/config.go — the mapping of user-provided reasoning_keywords onto StrongReasoningKeywords only, leaving WeakReasoningKeywords as hidden defaults, is worth a follow-up documentation or API clarification. Important Files Changed
Reviews (17): Last reviewed commit: "complexity router : add complexity analy..." | Re-trigger Greptile |
89613dd to
7a674e4
Compare
0dbc48b to
88e2f0e
Compare
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (1)
plugins/governance/main.go (1)
1050-1077: ⚡ Quick winMemoize lazy complexity evaluation per request.
computeComplexitycan be invoked multiple times during a single routing evaluation, which repeats analysis and emits duplicate logs. Cache the first result in the closure.♻️ Proposed change
// Set up lazy complexity computation; only runs if a rule actually references "complexity_tier". var computeComplexity func() *complexity.ComplexityResult if analyzer := p.complexityAnalyzer.Load(); analyzer != nil { + var cached *complexity.ComplexityResult + computed := false computeComplexity = func() *complexity.ComplexityResult { + if computed { + return cached + } + computed = true if input, ok := buildComplexityInput(ctx, body); ok { result := analyzer.Analyze(input) if p.logger != nil { p.logger.Debug( "[Governance] Complexity analysis details: tier=%s score=%.2f words=%d", result.Tier, result.Score, result.WordCount, ) } ctx.AppendRoutingEngineLog( schemas.RoutingEngineRoutingRule, schemas.LogLevelInfo, fmt.Sprintf("Complexity: tier=%s score=%.2f words=%d", result.Tier, result.Score, result.WordCount), ) - return result + cached = result + return cached } if p.logger != nil { p.logger.Debug("[Governance] Complexity analysis skipped: unsupported request type") } ctx.AppendRoutingEngineLog(schemas.RoutingEngineRoutingRule, schemas.LogLevelInfo, "Complexity analysis skipped: no supported text-bearing input detected") - return nil + cached = nil + return nil } }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@plugins/governance/main.go` around lines 1050 - 1077, The computeComplexity closure currently re-runs buildComplexityInput and analyzer.Analyze on every call, causing duplicate analysis and logs; change the closure (created when p.complexityAnalyzer.Load() != nil) to memoize the outcome by introducing a closure-scoped variable (e.g., cached *complexity.ComplexityResult and a bool like computed) so the first invocation runs buildComplexityInput -> analyzer.Analyze, emits the p.logger.Debug and ctx.AppendRoutingEngineLog entries, stores the result in cached and sets computed=true, and subsequent calls simply return cached (or nil) without repeating analysis or logging; keep existing logic paths (unsupported input logs once) and use the same identifying functions: computeComplexity, p.complexityAnalyzer.Load(), buildComplexityInput, analyzer.Analyze, p.logger.Debug, and ctx.AppendRoutingEngineLog.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@framework/configstore/complexityconfig.go`:
- Around line 109-127: The normalizeComplexityKeywordList function currently
dedupes and preserves input order causing non-deterministic output; after
building the deduped slice `out` in normalizeComplexityKeywordList, sort it
deterministically (e.g., call sort.Strings(out)) before returning to ensure
canonical ordering; also add the "sort" import if it's not already present so
the function compiles.
In `@transports/bifrost-http/lib/config.go`:
- Around line 2687-2697: The write to ComplexityAnalyzerConfig inside the
ExecuteTransaction closure is not using the transaction (it calls
config.ConfigStore.UpdateComplexityAnalyzerConfig(ctx, normalized)), so make the
update transactional by adding a tx-aware API and using the transaction variable
from the closure: either change UpdateComplexityAnalyzerConfig to accept a tx
(e.g., UpdateComplexityAnalyzerConfig(ctx, tx, cfg)) or add
UpdateComplexityAnalyzerConfigTx(ctx, tx, cfg), then update the rdb
implementation to pass the tx into s.UpdateConfig (use the provided tx instead
of s.DB()) and call the tx-aware method from the ExecuteTransaction closure so
the complexity config persistence is included in the surrounding transaction.
---
Nitpick comments:
In `@plugins/governance/main.go`:
- Around line 1050-1077: The computeComplexity closure currently re-runs
buildComplexityInput and analyzer.Analyze on every call, causing duplicate
analysis and logs; change the closure (created when p.complexityAnalyzer.Load()
!= nil) to memoize the outcome by introducing a closure-scoped variable (e.g.,
cached *complexity.ComplexityResult and a bool like computed) so the first
invocation runs buildComplexityInput -> analyzer.Analyze, emits the
p.logger.Debug and ctx.AppendRoutingEngineLog entries, stores the result in
cached and sets computed=true, and subsequent calls simply return cached (or
nil) without repeating analysis or logging; keep existing logic paths
(unsupported input logs once) and use the same identifying functions:
computeComplexity, p.complexityAnalyzer.Load(), buildComplexityInput,
analyzer.Analyze, p.logger.Debug, and ctx.AppendRoutingEngineLog.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 26e4243f-3cc5-4310-868a-fcb4c49008b2
📒 Files selected for processing (17)
framework/configstore/clientconfig.goframework/configstore/complexityconfig.goframework/configstore/rdb.goframework/configstore/rdb_test.goframework/configstore/store.goframework/configstore/tables/config.goplugins/governance/complexity/analyzer.goplugins/governance/complexity/analyzer_test.goplugins/governance/complexity/config.goplugins/governance/complexity/matcher.goplugins/governance/main.gotransports/bifrost-http/handlers/governance.gotransports/bifrost-http/handlers/governance_test.gotransports/bifrost-http/lib/config.gotransports/bifrost-http/lib/config_test.gotransports/bifrost-http/server/server.gotransports/config.schema.json
✅ Files skipped from review due to trivial changes (1)
- framework/configstore/tables/config.go
88e2f0e to
34d7901
Compare
7a674e4 to
97c557c
Compare
34d7901 to
92c82f1
Compare
97c557c to
299b806
Compare
There was a problem hiding this comment.
🧹 Nitpick comments (2)
plugins/governance/main.go (1)
1051-1077: ⚡ Quick winMemoize per-request complexity computation inside
computeComplexity.Line 1051 currently recalculates/analyzes on every invocation. If multiple rules/functions touch complexity fields in one evaluation, this repeats scans and duplicate logs unnecessarily.
♻️ Proposed change
var computeComplexity func() *complexity.ComplexityResult if analyzer := p.complexityAnalyzer.Load(); analyzer != nil { + var ( + computed bool + cached *complexity.ComplexityResult + ) computeComplexity = func() *complexity.ComplexityResult { + if computed { + return cached + } + computed = true + if input, ok := buildComplexityInput(ctx, body); ok { - result := analyzer.Analyze(input) + cached = analyzer.Analyze(input) if p.logger != nil { p.logger.Debug( "[Governance] Complexity analysis details: tier=%s score=%.2f words=%d", - result.Tier, - result.Score, - result.WordCount, + cached.Tier, + cached.Score, + cached.WordCount, ) } ctx.AppendRoutingEngineLog( schemas.RoutingEngineRoutingRule, schemas.LogLevelInfo, - fmt.Sprintf("Complexity: tier=%s score=%.2f words=%d", result.Tier, result.Score, result.WordCount), + fmt.Sprintf("Complexity: tier=%s score=%.2f words=%d", cached.Tier, cached.Score, cached.WordCount), ) - return result + return cached } if p.logger != nil { p.logger.Debug("[Governance] Complexity analysis skipped: unsupported request type") } ctx.AppendRoutingEngineLog(schemas.RoutingEngineRoutingRule, schemas.LogLevelInfo, "Complexity analysis skipped: no supported text-bearing input detected") return nil } }Also applies to: 1088-1088
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@plugins/governance/main.go` around lines 1051 - 1077, The computeComplexity closure currently runs analyzer.Analyze and emits logs on every call; change it to memoize the result per request by introducing a local cached variable (e.g., cached *complexity.ComplexityResult and a flag like computed bool) inside the scope where computeComplexity is defined and have the closure return the cached value if computed is true. Ensure buildComplexityInput, analyzer.Analyze, p.logger.Debug and ctx.AppendRoutingEngineLog are only invoked when computing the result the first time (store the result in cached and set computed), and subsequent calls simply return cached without re-running analysis or re-logging.transports/bifrost-http/lib/config_test.go (1)
1364-1364: ⚡ Quick winAvoid pointer-identity assertion in this test.
require.Same(...)makes the test fragile by enforcing aliasing, not behavior. A valid implementation that deep-copies/normalizes can fail this test even when semantics are correct. Prefer value-based assertions on normalized content instead.Suggested change
- require.Same(t, store.complexityConfig, config.GovernanceConfig.ComplexityAnalyzerConfig) + require.NotNil(t, config.GovernanceConfig.ComplexityAnalyzerConfig) + require.Equal(t, store.complexityConfig.TierBoundaries, config.GovernanceConfig.ComplexityAnalyzerConfig.TierBoundaries) + require.Equal(t, store.complexityConfig.Keywords, config.GovernanceConfig.ComplexityAnalyzerConfig.Keywords)🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@transports/bifrost-http/lib/config_test.go` at line 1364, The test currently uses pointer-identity assertion require.Same(t, store.complexityConfig, config.GovernanceConfig.ComplexityAnalyzerConfig) which is fragile; replace it with a value-based assertion that verifies the semantics rather than aliasing. Change the assertion to compare the contents of store.complexityConfig and config.GovernanceConfig.ComplexityAnalyzerConfig (for example using require.Equal / require.EqualValues or a deep-compare/cmp.Diff on those structs) or compare specific normalized fields if normalization is required before comparing; ensure you remove the require.Same usage and assert equality of values instead.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@plugins/governance/main.go`:
- Around line 1051-1077: The computeComplexity closure currently runs
analyzer.Analyze and emits logs on every call; change it to memoize the result
per request by introducing a local cached variable (e.g., cached
*complexity.ComplexityResult and a flag like computed bool) inside the scope
where computeComplexity is defined and have the closure return the cached value
if computed is true. Ensure buildComplexityInput, analyzer.Analyze,
p.logger.Debug and ctx.AppendRoutingEngineLog are only invoked when computing
the result the first time (store the result in cached and set computed), and
subsequent calls simply return cached without re-running analysis or re-logging.
In `@transports/bifrost-http/lib/config_test.go`:
- Line 1364: The test currently uses pointer-identity assertion require.Same(t,
store.complexityConfig, config.GovernanceConfig.ComplexityAnalyzerConfig) which
is fragile; replace it with a value-based assertion that verifies the semantics
rather than aliasing. Change the assertion to compare the contents of
store.complexityConfig and config.GovernanceConfig.ComplexityAnalyzerConfig (for
example using require.Equal / require.EqualValues or a deep-compare/cmp.Diff on
those structs) or compare specific normalized fields if normalization is
required before comparing; ensure you remove the require.Same usage and assert
equality of values instead.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 38781847-5c69-482c-9bb8-84c25dd9c05f
📒 Files selected for processing (17)
framework/configstore/clientconfig.goframework/configstore/complexityconfig.goframework/configstore/rdb.goframework/configstore/rdb_test.goframework/configstore/store.goframework/configstore/tables/config.goplugins/governance/complexity/analyzer.goplugins/governance/complexity/analyzer_test.goplugins/governance/complexity/config.goplugins/governance/complexity/matcher.goplugins/governance/main.gotransports/bifrost-http/handlers/governance.gotransports/bifrost-http/handlers/governance_test.gotransports/bifrost-http/lib/config.gotransports/bifrost-http/lib/config_test.gotransports/bifrost-http/server/server.gotransports/config.schema.json
✅ Files skipped from review due to trivial changes (1)
- framework/configstore/tables/config.go
b2756f5 to
d7bff03
Compare
299b806 to
898afcc
Compare
There was a problem hiding this comment.
🧹 Nitpick comments (1)
framework/configstore/complexityconfig.go (1)
110-130: 💤 Low valueConsider returning
nilfor all-empty results to match the empty-input pattern.The function returns
nilfor an empty input (line 112), but returns an empty slice[]string{}when all values are blank or duplicates after normalization. For consistency and to avoid allocating an empty slice, returnnilwhenoutis empty.♻️ Proposed consistency fix
seen := make(map[string]struct{}, len(values)) out := make([]string, 0, len(values)) for _, value := range values { normalized := strings.ToLower(strings.TrimSpace(value)) if normalized == "" { continue } if _, ok := seen[normalized]; ok { continue } seen[normalized] = struct{}{} out = append(out, normalized) } + if len(out) == 0 { + return nil + } sort.Strings(out) return out }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@framework/configstore/complexityconfig.go` around lines 110 - 130, normalizeComplexityKeywordList currently returns nil for empty input but returns a non-nil empty slice when all entries normalize away; update the function so that after building out it returns nil if len(out) == 0 (i.e., replace the final return with a conditional that returns nil when out is empty) to keep the empty-input/empty-result behavior consistent and avoid allocating an empty slice.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@framework/configstore/complexityconfig.go`:
- Around line 110-130: normalizeComplexityKeywordList currently returns nil for
empty input but returns a non-nil empty slice when all entries normalize away;
update the function so that after building out it returns nil if len(out) == 0
(i.e., replace the final return with a conditional that returns nil when out is
empty) to keep the empty-input/empty-result behavior consistent and avoid
allocating an empty slice.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 052848a3-082d-4d19-8e00-4b50e830bbb4
📒 Files selected for processing (17)
framework/configstore/clientconfig.goframework/configstore/complexityconfig.goframework/configstore/rdb.goframework/configstore/rdb_test.goframework/configstore/store.goframework/configstore/tables/config.goplugins/governance/complexity/analyzer.goplugins/governance/complexity/analyzer_test.goplugins/governance/complexity/config.goplugins/governance/complexity/matcher.goplugins/governance/main.gotransports/bifrost-http/handlers/governance.gotransports/bifrost-http/handlers/governance_test.gotransports/bifrost-http/lib/config.gotransports/bifrost-http/lib/config_test.gotransports/bifrost-http/server/server.gotransports/config.schema.json
💤 Files with no reviewable changes (6)
- transports/config.schema.json
- transports/bifrost-http/server/server.go
- transports/bifrost-http/handlers/governance.go
- transports/bifrost-http/handlers/governance_test.go
- transports/bifrost-http/lib/config.go
- transports/bifrost-http/lib/config_test.go
✅ Files skipped from review due to trivial changes (1)
- framework/configstore/tables/config.go
🚧 Files skipped from review as they are similar to previous changes (9)
- framework/configstore/store.go
- framework/configstore/clientconfig.go
- plugins/governance/complexity/matcher.go
- plugins/governance/complexity/analyzer.go
- plugins/governance/complexity/analyzer_test.go
- plugins/governance/complexity/config.go
- framework/configstore/rdb.go
- plugins/governance/main.go
- framework/configstore/rdb_test.go
d7bff03 to
5f16493
Compare
898afcc to
cbe2f5a
Compare
|
✅ Actions performedFull review triggered. |
There was a problem hiding this comment.
Actionable comments posted: 5
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@framework/configstore/rdb_test.go`:
- Around line 116-125: Extend
TestRDBConfigStore_UpdateComplexityAnalyzerConfigRejectsInvalidConfig into a
table-driven test that exercises additional invalid cases for
UpdateComplexityAnalyzerConfig: create variants of
testComplexityAnalyzerConfig() where TierBoundaries contain values ≤0 or ≥1
(e.g., -0.1, 0, 1.0), where ordering is wrong (e.g., ComplexReasoning <
MediumComplex), and where keyword arrays required by the schema are empty; for
each variant call store.UpdateComplexityAnalyzerConfig(ctx, invalid) and assert
require.Error(t, err). Reference the existing test name
TestRDBConfigStore_UpdateComplexityAnalyzerConfigRejectsInvalidConfig, the
helper testComplexityAnalyzerConfig(), and the UpdateComplexityAnalyzerConfig
method and TierBoundaries fields to locate and implement these cases.
In `@plugins/governance/complexity/analyzer.go`:
- Around line 5-10: The comment on ComplexityAnalyzer is incorrect: it no longer
is stateless because it stores immutable configuration in tierBoundaries and
matcher; update the struct comment for ComplexityAnalyzer to say it holds
immutable configuration (tierBoundaries and matcher) and remains safe for
concurrent use rather than calling it "stateless". Mention the specific fields
(tierBoundaries, matcher) and that they are immutable after construction and
concurrency-safe.
In `@transports/bifrost-http/handlers/governance.go`:
- Around line 528-533: When persisting new runtime configs you must make the
write rollback-aware: before calling UpdateComplexityAnalyzerConfig take and
keep the current config (via the store or an existing getter), then call
UpdateComplexityAnalyzerConfig(ctx, normalized); if
reloadComplexityAnalyzerConfig(ctx, normalized) fails, perform a compensating
rollback by calling UpdateComplexityAnalyzerConfig(ctx, previous) (and log both
the reload and rollback outcomes via process logger/SendError), return 500 only
after attempting rollback; apply the same pattern to the other handlers
referenced (the methods around lines 547-552 and 559-564) that persist then
reload so persistent store and in-memory state never diverge.
In `@transports/bifrost-http/lib/config_test.go`:
- Line 389: Tests store complexity config in two separate fields
(complexityConfig and governanceConfig.ComplexityAnalyzerConfig) causing drift;
update the mock store so there is a single source of truth: pick one canonical
field (e.g., governanceConfig.ComplexityAnalyzerConfig) and make all
setters/getters and seed logic (including any functions like
SetComplexityAnalyzerConfig, GetComplexityAnalyzerConfig, and the test seeding
paths around complexityConfig) read from and write to that canonical field only,
and remove or forward the duplicate complexityConfig field so reads behave the
same as the real store.
- Line 1427: The test currently asserts pointer identity with require.Same on
store.complexityConfig vs config.GovernanceConfig.ComplexityAnalyzerConfig;
change this to a value equality assertion (e.g., require.Equal or
require.EqualValues) so the test verifies the configs' contents rather than
pointer identity, avoiding fragile failures when a defensive copy is returned.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 14a5b74f-0a9d-492c-93c9-40f02d170342
📒 Files selected for processing (17)
framework/configstore/clientconfig.goframework/configstore/complexityconfig.goframework/configstore/rdb.goframework/configstore/rdb_test.goframework/configstore/store.goframework/configstore/tables/config.goplugins/governance/complexity/analyzer.goplugins/governance/complexity/analyzer_test.goplugins/governance/complexity/config.goplugins/governance/complexity/matcher.goplugins/governance/main.gotransports/bifrost-http/handlers/governance.gotransports/bifrost-http/handlers/governance_test.gotransports/bifrost-http/lib/config.gotransports/bifrost-http/lib/config_test.gotransports/bifrost-http/server/server.gotransports/config.schema.json
62a6254 to
b0f60d8
Compare
deb50b7 to
00d7bee
Compare
b0f60d8 to
3dfab94
Compare
00d7bee to
7e06261
Compare
3dfab94 to
f9750b3
Compare
7e06261 to
aa8c316
Compare
9917bc3 to
c10fe4d
Compare
aa8c316 to
8377b5a
Compare
c10fe4d to
7f30ad6
Compare
8377b5a to
87b2afc
Compare
7f30ad6 to
45d048c
Compare
feb5264 to
4d0a27b
Compare
45d048c to
2abea67
Compare
Merge activity
|
The base branch was changed.
4d0a27b to
d7fc48a
Compare
…#3712) ## Summary Briefly explain the purpose of this PR and the problem it solves. ## Changes - What was changed and why - Any notable design decisions or trade-offs ## Type of change - [ ] Bug fix - [ ] Feature - [ ] Refactor - [ ] Documentation - [ ] Chore/CI ## Affected areas - [ ] Core (Go) - [ ] Transports (HTTP) - [ ] Providers/Integrations - [ ] Plugins - [ ] UI (React) - [ ] Docs ## How to test Describe the steps to validate this change. Include commands and expected outcomes. ```sh # Core/Transports go version go test ./... # UI cd ui pnpm i || npm i pnpm test || npm test pnpm build || npm run build ``` If adding new configs or environment variables, document them here. ## Screenshots/Recordings If UI changes, add before/after screenshots or short clips. ## Breaking changes - [ ] Yes - [ ] No If yes, describe impact and migration instructions. ## Related issues Link related issues and discussions. Example: Closes #123 ## Security considerations Note any security implications (auth, secrets, PII, sandboxing, etc.). ## Checklist - [ ] I read `docs/contributing/README.md` and followed the guidelines - [ ] I added/updated tests where appropriate - [ ] I updated documentation where needed - [ ] I verified builds succeed (Go and UI) - [ ] I verified the CI pipeline passes locally if applicable <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Release Notes * **New Features** * Added HTTP endpoints for managing complexity analyzer configuration (`GET`, `PUT`, `POST /reset`) * Complexity analyzer settings now support customizable tier boundaries and keyword lists * Configuration persists across service restarts with runtime reload capability * Configuration validation enforces integrity of tier boundaries and keyword definitions <!-- end of auto-generated comment: release notes by coderabbit.ai -->

Summary
Briefly explain the purpose of this PR and the problem it solves.
Changes
Type of change
Affected areas
How to test
Describe the steps to validate this change. Include commands and expected outcomes.
If adding new configs or environment variables, document them here.
Screenshots/Recordings
If UI changes, add before/after screenshots or short clips.
Breaking changes
If yes, describe impact and migration instructions.
Related issues
Link related issues and discussions. Example: Closes #123
Security considerations
Note any security implications (auth, secrets, PII, sandboxing, etc.).
Checklist
docs/contributing/README.mdand followed the guidelinesSummary by CodeRabbit
Release Notes
GET,PUT,POST /reset)