third step

This commit is contained in:
team2
2026-04-29 21:27:24 +02:00
parent b71adf33f0
commit 8ece67b461
7 changed files with 220 additions and 140 deletions

View File

@@ -0,0 +1,91 @@
# RetrieX Patch 3: IntentLight + SalesIntent YAML-only
This patch continues the incremental YAML-source-of-truth migration.
## Scope
Only these intent areas are changed:
- `IntentLightConfig`
- `SalesIntentConfig`
- direct usages of their former PHP constants
- the effective-config dump for these values
- `config/retriex/intent.yaml`
No retrieval, prompt, shop, commerce-parser, SSE, or answer-generation logic is changed.
## What changed
### IntentLightConfig
Removed PHP defaults:
- `LIST_THRESHOLD`
- `QUANTITY_WORDS`
- `STRONG_PATTERNS`
Added required YAML-backed accessors:
- `getListThreshold()`
- `getQuantityWords()`
- `getStrongPatterns()`
The previous values now live in:
```yaml
retriex.intent.light.config:
list_threshold: 4
quantity_words: [...]
strong_patterns: [...]
```
### SalesIntentConfig
Removed PHP defaults:
- `DOMINANCE_DELTA`
- `MIN_SCORE_THRESHOLD`
- `SALES_SIGNALS`
- `COMPARISON_SIGNALS`
- `OBJECTION_SIGNALS`
- `IMPLEMENTATION_SIGNALS`
- `ROI_SIGNALS`
Added required YAML-backed accessors:
- `getDominanceDelta()`
- `getMinScoreThreshold()`
- `getSalesSignals()`
- `getComparisonSignals()`
- `getObjectionSignals()`
- `getImplementationSignals()`
- `getRoiSignals()`
The previous values now live in:
```yaml
retriex.intent.sales.config:
dominance_delta: 2
min_score_threshold: 3
sales_signals: [...]
comparison_signals: [...]
objection_signals: [...]
implementation_signals: [...]
roi_signals: [...]
```
## Validation performed
Static validation in the patch workspace:
```bash
php -l src/Config/IntentLightConfig.php
php -l src/Config/SalesIntentConfig.php
php -l src/Intent/IntentLite.php
php -l src/Intent/SalesIntentLite.php
php -l src/Config/RetriexEffectiveConfigProvider.php
```
YAML was parsed successfully with the new keys.
The full Symfony regression commands were not executed in the extracted ZIP workspace because `vendor/` is not part of the uploaded archive.