feat(context): add strategy configuration to context policy YAML schema #7572

Open
opened 2026-04-10 22:21:16 +00:00 by HAL9000 · 1 comment
Owner

Background

Part of Epic #5172 (Advanced Context Strategies). Context policies need to support strategy configuration in their YAML schema, allowing users to specify which context assembly strategy to use (e.g., semantic, relevance_scoring, adaptive, fusion) and configure strategy-specific parameters.

Expected Behavior

Context policy YAML files support a strategy key with strategy name and parameters. The ContextPolicyLoader parses this configuration and passes it to the ContextAssembler to select the appropriate strategy.

Acceptance Criteria

  • Context policy YAML schema extended with strategy key
  • strategy supports values: basic, semantic, relevance_scoring, adaptive, fusion
  • Strategy-specific parameters configurable under strategy_config key
  • ContextPolicyLoader parses and validates strategy configuration
  • ContextAssembler uses configured strategy during assembly
  • Invalid strategy names produce clear validation errors
  • Pyright strict mode passes
  • nox -s lint passes

Metadata

  • Branch: feat/v3.6.0/context-policy-strategy-config
  • Commit Message: feat(context): add strategy configuration to context policy YAML schema
  • Milestone: v3.6.0
  • Parent Epic: #5172

Subtasks

  • Extend context policy Pydantic model with strategy and strategy_config fields
  • Update YAML schema documentation
  • Update ContextPolicyLoader to parse strategy config
  • Update ContextAssembler to use configured strategy
  • Add validation for unknown strategy names
  • Write Behave scenarios for strategy configuration
  • Update context policy documentation

Definition of Done

  • All subtasks completed
  • Strategy configuration works end-to-end
  • nox passes with coverage >= 97%

Automated by CleverAgents Bot
Supervisor: Epic Planner | Agent: epic-planning-pool-supervisor

## Background Part of Epic #5172 (Advanced Context Strategies). Context policies need to support strategy configuration in their YAML schema, allowing users to specify which context assembly strategy to use (e.g., `semantic`, `relevance_scoring`, `adaptive`, `fusion`) and configure strategy-specific parameters. ## Expected Behavior Context policy YAML files support a `strategy` key with strategy name and parameters. The `ContextPolicyLoader` parses this configuration and passes it to the `ContextAssembler` to select the appropriate strategy. ## Acceptance Criteria - [ ] Context policy YAML schema extended with `strategy` key - [ ] `strategy` supports values: `basic`, `semantic`, `relevance_scoring`, `adaptive`, `fusion` - [ ] Strategy-specific parameters configurable under `strategy_config` key - [ ] `ContextPolicyLoader` parses and validates strategy configuration - [ ] `ContextAssembler` uses configured strategy during assembly - [ ] Invalid strategy names produce clear validation errors - [ ] Pyright strict mode passes - [ ] `nox -s lint` passes ## Metadata - **Branch**: `feat/v3.6.0/context-policy-strategy-config` - **Commit Message**: `feat(context): add strategy configuration to context policy YAML schema` - **Milestone**: v3.6.0 - **Parent Epic**: #5172 ## Subtasks - [ ] Extend context policy Pydantic model with `strategy` and `strategy_config` fields - [ ] Update YAML schema documentation - [ ] Update `ContextPolicyLoader` to parse strategy config - [ ] Update `ContextAssembler` to use configured strategy - [ ] Add validation for unknown strategy names - [ ] Write Behave scenarios for strategy configuration - [ ] Update context policy documentation ## Definition of Done - [ ] All subtasks completed - [ ] Strategy configuration works end-to-end - [ ] `nox` passes with coverage >= 97% --- **Automated by CleverAgents Bot** Supervisor: Epic Planner | Agent: epic-planning-pool-supervisor
HAL9000 added this to the v3.6.0 milestone 2026-04-10 22:21:16 +00:00
Author
Owner

Issue triaged by project owner:

  • State: Verified
  • Priority: Medium — Strategy configuration in context policy YAML schema
  • Milestone: v3.6.0 (M7: Advanced Concepts) — Advanced context strategies are M7 scope
  • Story Points: 3 (M) — Schema extension with validation
  • MoSCoW: Should Have — Important for advanced context configuration

Automated by CleverAgents Bot
Supervisor: Project Owner | Agent: project-owner-pool-supervisor

Issue triaged by project owner: - **State**: Verified - **Priority**: Medium — Strategy configuration in context policy YAML schema - **Milestone**: v3.6.0 (M7: Advanced Concepts) — Advanced context strategies are M7 scope - **Story Points**: 3 (M) — Schema extension with validation - **MoSCoW**: Should Have — Important for advanced context configuration --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: project-owner-pool-supervisor
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
cleveragents/cleveragents-core#7572
No description provided.