mirror of
https://github.com/semantica-agi/semantica.git
synced 2026-09-12 04:01:35 +00:00
fix(plugins): correct the extraction cache import in extract and validate
Both skills instruct the agent to clear the result cache via `from semantica.semantic_extract.cache import _result_cache`, but the module exports the `ExtractionCache` singleton as `extraction_cache`. The private name never existed, so the first step of both skills raises ImportError. `extraction_cache.clear()` is the equivalent call. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -21,8 +21,8 @@ Run the full extraction pipeline. Usage: `/semantica:extract [file_path | "inlin
|
||||
**2. Clear the result cache** to prevent cross-invocation pollution:
|
||||
|
||||
```python
|
||||
from semantica.semantic_extract.cache import _result_cache
|
||||
_result_cache.clear()
|
||||
from semantica.semantic_extract.cache import extraction_cache
|
||||
extraction_cache.clear()
|
||||
```
|
||||
|
||||
**3. Run the full pipeline:**
|
||||
|
||||
@@ -119,9 +119,9 @@ from semantica.semantic_extract import (
|
||||
NamedEntityRecognizer,
|
||||
RelationExtractor,
|
||||
)
|
||||
from semantica.semantic_extract.cache import _result_cache
|
||||
from semantica.semantic_extract.cache import extraction_cache
|
||||
|
||||
_result_cache.clear() # prevent cross-invocation cache pollution
|
||||
extraction_cache.clear() # prevent cross-invocation cache pollution
|
||||
|
||||
text = open(file_path).read()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user