Troubleshooting
Troubleshoot query concept expansion — Unified Discovery
Diagnose misleading query expansions, unsupported synonyms, stale terminology, altered scientific meaning, or unauthorized sources in discovery results.
Application: Unified Discovery
Cross-application area: Scientific Discovery / Library / Research / Terminology Governance
Classification: Troubleshooting / Query Concept Expansion
Audience: Researchers, research librarians, information specialists, knowledge engineers, support engineers, and research software developers
Technical level: Intermediate to advanced
Reference environment: Python 3.10 or later; standard library only
Relevant specifications: W3C SKOS, W3C PROV-O, PRISMA-S, RFC 9110, and RFC 9457
Primary outputs: Query-expansion diagnosis, mapping reconciliation, exclusion verification, provider execution assessment, safe recovery record, and regression evidence
Estimated reading time: 15–20 minutes; approximately 35–45 minutes including practical exercises
1. Recognize a query concept expansion failure
Query concept expansion fails when additional search expressions change the intended scientific meaning, remove necessary restrictions, introduce unsupported terminology, or produce retrieval results that cannot be adequately explained or reproduced.
Some failures are immediately visible. Others are difficult to detect because the expanded query executes successfully and produces plausible-looking results.
Typical symptoms include:
- The expanded query retrieves substantially more unrelated material.
- An exact synonym is replaced by a broader or merely related concept.
- An ambiguous abbreviation introduces material from an unrelated discipline.
- Original search terms disappear from the final query.
- Previously defined exclusions are missing.
- Boolean operators or parentheses change unexpectedly.
- Terms marked as rejected or pending review appear in the executed query.
- The interface shows an expanded search without revealing the added terms.
- The query behaves differently across providers.
- Terminology mappings refer to stale or missing vocabulary revisions.
- Search results cannot be reconciled with the recorded query.
- Provider outages produce incomplete coverage that is presented as complete.
- A saved query changes after reloading or switching sessions.
- A user cannot access the terminology source or research project needed for review.
- A downstream research output relies on an unreviewed or incorrectly expanded search.
Primary acceptance condition: Every query change is visible and traceable, including accepted terms, rejected candidates, review-required candidates, original exclusions, and the final provider-specific executed queries.
A successful HTTP response or a higher result count is not sufficient evidence of successful scientific expansion.
2. Classify the failure before attempting recovery
| Failure class | Likely cause | Initial diagnostic action |
|---|---|---|
| Semantic drift | A broader or related concept was treated as equivalent | Compare mapping relationship and original scientific definition |
| Abbreviation ambiguity | One abbreviation represents multiple concepts | Inspect terminology context and disambiguation record |
| Missing exclusion | Original query restriction was dropped | Compare original and expanded exclusion sets |
| Boolean logic defect | Operator precedence or grouping changed | Inspect the logical query structure |
| Unsupported mapping | Term lacks reviewed terminology provenance | Resolve vocabulary source and revision |
| Unauthorized mapping | Candidate accepted without required authority | Inspect trusted reviewer and approval records |
| Stale mapping | Saved expansion uses an outdated or incompatible vocabulary revision | Reconcile mapping versions |
| Provider mismatch | Provider translates or interprets the query differently | Inspect the exact executed provider query |
| Partial retrieval | Timeout, rate limit, unavailable provider, or incomplete pagination | Inspect coverage and provider results |
| Persistence mismatch | Saved query does not match displayed query | Inspect authoritative saved revision |
| Authorization failure | Research project, terminology, or source access denied | Verify trusted identity and object permissions |
| Retrieval quality degradation | Added terms retrieve disproportionate nonrelevant material | Compare relevance judgments and retrieval metrics |
Different failure categories require different recovery actions. Correcting a provider-query renderer will not repair a scientifically invalid mapping, and editing a terminology mapping will not resolve an authentication failure.
3. Follow the diagnostic sequence
- Preserve the original query. Capture its exact expression, parameters, exclusions, and revision.
- Identify the research context. Confirm project, organization, responsible role, time scope, and intended scientific concepts.
- Inspect the expansion ledger. Identify every candidate, relationship type, decision, and supporting source.
- Reconcile exclusions. Ensure no original restriction was silently removed or weakened.
- Inspect query logic. Compare Boolean operators, grouping, field restrictions, and provider-specific syntax.
- Verify mapping provenance. Resolve the cited vocabulary or approved terminology record and its revision.
- Check authorization. Confirm that any saved-query changes and terminology approvals were permitted.
- Inspect provider execution. Verify the actual submitted query, provider responses, and coverage.
- Evaluate retrieval effects. Compare source sets and relevance judgments where available.
- Determine downstream impact. Identify Library selections, research analyses, or publications dependent on the affected query.
- Recover safely. Revert or correct the narrowest defective mapping, query revision, or adapter.
- Rerun acceptance. Verify scientific meaning, exclusions, query transparency, provider execution, and persistence.
Do not immediately replace the expanded query with another automatically generated query. First determine what caused the original failure.
4. Verify the original scientific meaning
Scientific query expansion must preserve the meaning of the original research question unless a scope change is deliberate, documented, and approved.
Consider this illustrative question:
What empirical evidence supports measurement of carbon dioxide removal through enhanced rock weathering in agricultural soils?
The information need includes an intervention, outcome, setting, and evidence requirement.
A query-expansion defect may occur when a specific term such as enhanced rock weathering is replaced by the broader expression rock weathering.
That change can introduce studies of natural geological weathering outside the intended intervention.
The broader literature may be useful for background research, but it should not silently replace the original intervention concept.
Validate the concepts against the actual research protocol, not merely against string similarity.
5. Distinguish synonyms from other concept relationships
W3C SKOS provides a useful conceptual distinction between exact, close, broader, narrower, and related mappings.
| Mapping | Interpretation | Failure to investigate |
|---|---|---|
| Exact match | Concepts are equivalent within the applicable mapping framework | Incorrect or outdated equivalence mapping |
| Close match | Concepts are sufficiently similar in a defined context | Context or limitations not preserved |
| Abbreviation | Acronym or shortened expression | Unresolved multiple meanings |
| Broader match | Candidate is more general than original | Unapproved widening of research scope |
| Narrower match | Candidate is more specific than original | Unintended narrowing or incomplete coverage |
| Related match | Concepts are associated without equivalence | Related topic incorrectly used as synonym |
A close match should not automatically be treated as an exact match. Nor should an associative relationship be promoted to equivalence simply because the associated terms frequently appear together.
For vocabulary-based mappings, inspect the actual concept definitions, identifiers, and mapping relationships.
6. Detect semantic drift
Semantic drift occurs when the meaning of the expanded query changes relative to the original information need.
For example:
Original:
"carbon dioxide removal"
Unreviewed expansion:
"carbon dioxide removal"
OR "carbon sequestration"
OR "carbon storage"
OR "carbon mitigation"
These expressions may overlap in some contexts, but they do not necessarily represent the same scientific concept or accounting boundary.
Diagnose semantic drift by asking:
- What exact scientific concept did the original expression represent?
- Does the candidate term represent the same process or outcome?
- Does it change the measurement or accounting boundary?
- Does it introduce studies outside the original population or intervention?
- Is the relationship documented in an appropriate terminology source?
- Has a qualified reviewer approved this mapping for the research context?
If the expansion changes the research question, classify it as a new exploratory query or approved protocol amendment rather than treating it as a routine synonym substitution.
7. Diagnose missing or hidden exclusions
Exclusion integrity is an independent acceptance requirement.
Consider:
Original query:
(A AND B AND C) NOT X
Expanded query:
(A OR A1) AND (B OR B1) AND C
The expanded query no longer includes the original exclusion X.
Even if the new query returns relevant documents, this is an unexplained change in the search protocol.
Inspect:
- Original Boolean exclusions.
- Field-specific restrictions.
- Publication date limits.
- Geographic or population criteria.
- Source-type restrictions.
- Research protocol screening exclusions.
- Rejected or pending expansion candidates.
Do not confuse a rejected terminology candidate with a document-exclusion criterion. They are distinct records and should be preserved separately.
Original exclusions must not be silently deleted, reinterpreted, or hidden by the interface.
8. Verify Boolean query structure
Boolean grouping can change which concepts a document must satisfy.
For example:
Intended:
(A OR A1)
AND
(B OR B1)
AND
(C OR C1)
Compare with:
Incorrect:
A OR A1 OR B OR B1 OR C OR C1
The second query permits a record to match only one concept group, potentially producing large numbers of irrelevant results.
Inspect the logical query representation before evaluating provider-specific syntax.
Do not diagnose a Boolean issue solely by reading a human-friendly search summary. Compare the actual executed query and the provider’s documented operator behavior.
9. Diagnose ambiguous abbreviations
Scientific abbreviations may represent different concepts in different disciplines.
A valid abbreviation expansion requires contextual disambiguation.
Check:
- The approved long-form concept.
- The scientific discipline.
- Alternative possible meanings.
- Provider subject classification or field restrictions.
- Terminology mapping provenance.
- Reviewer approval where needed.
Do not globally replace every occurrence of an abbreviation with one scientific concept.
Where ambiguity cannot be resolved, hold the candidate for review or use an explicit, context-restricted exploratory query.
10. Inspect terminology provenance and revisions
A saved expansion may become stale when a controlled vocabulary, mapping registry, or scientific protocol changes.
Inspect:
- Original concept identifier.
- Candidate concept identifier.
- Vocabulary or terminology source.
- Vocabulary revision.
- Mapping relationship.
- Mapping review status.
- Applicable scientific context.
- Actual reviewer or approved workflow.
A stored vocabulary version string does not establish that the source record can still be resolved.
For production validation, verify the actual authoritative terminology record and compare its meaning with the mapping used by the query.
Do not silently replace historical mappings in a published research protocol with newer mappings without recording the change.
11. Diagnose provider-specific query differences
Federated discovery providers may interpret the same expression differently.
Differences can include:
- Boolean precedence.
- Phrase matching.
- Field restrictions.
- Stemming or lemmatization.
- Automatic thesaurus expansion.
- Case normalization.
- Language-specific tokenization.
- Pagination and query limits.
- Unsupported operators.
Preserve both the logical query and the exact submitted query for each provider.
If one provider does not support the intended search logic, disclose the limitation rather than asserting equivalent coverage.
A provider returning HTTP 200 establishes neither correct query interpretation nor scientific completeness.
12. Distinguish retrieval changes from retrieval improvements
Additional results do not automatically indicate improved research retrieval.
Evaluate:
- Total retrieved records.
- Unique records after deduplication.
- Records judged relevant.
- Newly retrieved relevant records.
- Newly retrieved nonrelevant records.
- Precision and recall against a defined reference set, where available.
- Provider coverage and failed requests.
- Whether the original scientific scope was preserved.
For a reference collection with known relevance judgments:
Precision = TP / (TP + FP)
Recall = TP / (TP + FN)
Where TP represents relevant retrieved records, FP represents nonrelevant retrieved records, and FN represents relevant records not retrieved.
Recall cannot generally be measured for all scientific literature without a defined evaluation collection or defensible estimation method.
Do not claim that a higher result count establishes better recall or better scientific evidence.
13. Diagnose incomplete provider coverage
A partial federated search can misleadingly suggest that concept expansion failed or succeeded.
For example:
Original search:
4 providers completed
Expanded search:
2 providers completed
1 rate limited
1 unavailable
The result sets are not directly comparable as though all other conditions were equal.
Record the provider set, execution time, result limits, pagination state, and failures for each query.
If expanded-query coverage is incomplete, label the evaluation accordingly and avoid attributing all differences to terminology expansion.
Recovery must not hide which providers failed.
14. Diagnose authorization and rights problems
Query expansion may use restricted terminology resources or project-specific research context.
Check that the authenticated user or service is permitted to:
- Access the relevant research project.
- Read the original query and its metadata.
- Use the required terminology source.
- Create or modify saved query revisions.
- Inspect retrieved source metadata.
- Store or export query and source records.
- Approve terminology mappings when authorized.
An available interface control does not establish permission.
Authorization must be enforced by trusted backend controls, including object-level and tenant-level checks.
Do not attempt to resolve a permissions failure by substituting another organization’s identifiers or bypassing project ownership checks.
15. Create a synthetic diagnostic fixture
The following example models an original query, its restrictions, and a reviewed expansion ledger.
| Original | Candidate | Relationship | Decision |
|---|---|---|---|
| enhanced rock weathering | accelerated rock weathering | near synonym | Accepted for synthetic fixture |
| enhanced rock weathering | rock weathering | broader | Rejected |
| carbon dioxide removal | CDR | abbreviation | Accepted for synthetic fixture |
| carbon dioxide removal | carbon sequestration | related | Rejected |
These mappings are illustrative and are not asserted to be independently certified scientific equivalences.
The diagnostic should identify unapproved expansion, missing exclusions, stale vocabulary revisions, and malformed mapping records without modifying the original query.
16. Implement the reference diagnostic module
Create a local directory using Python 3.10 or later:
mkdir query-expansion-diagnostics
cd query-expansion-diagnostics
python3 -m venv .venv
source .venv/bin/activate
python --version
Save the following as query_diagnostics.py.
from dataclasses import dataclass
import json
@dataclass(frozen=True)
class Mapping:
original: str
candidate: str
relationship: str
decision: str
vocabulary_revision: str
explanation: str
ORIGINAL = (
"enhanced rock weathering",
"carbon dioxide removal"
)
EXCLUSIONS = (
"outside-study-scope",
)
EXPECTED_VOCABULARY = "synthetic-v1"
MAPPINGS = (
Mapping(
"enhanced rock weathering",
"accelerated rock weathering",
"near_synonym",
"accepted",
EXPECTED_VOCABULARY,
"Synthetic context-limited mapping"
),
Mapping(
"enhanced rock weathering",
"rock weathering",
"broader",
"rejected",
EXPECTED_VOCABULARY,
"Wider intervention concept"
),
Mapping(
"carbon dioxide removal",
"CDR",
"abbreviation",
"accepted",
EXPECTED_VOCABULARY,
"Synthetic contextual disambiguation"
),
Mapping(
"carbon dioxide removal",
"carbon sequestration",
"related",
"rejected",
EXPECTED_VOCABULARY,
"Not necessarily equivalent"
)
)
ALLOWED_RELATIONSHIPS = {
"exact_synonym",
"near_synonym",
"abbreviation",
"broader",
"narrower",
"related"
}
EQUIVALENCE_CANDIDATES = {
"exact_synonym",
"near_synonym",
"abbreviation"
}
ALLOWED_DECISIONS = {
"accepted",
"rejected",
"review_required"
}
def diagnose(
original=ORIGINAL,
mappings=MAPPINGS,
required_exclusions=EXCLUSIONS,
actual_exclusions=EXCLUSIONS,
expected_revision=EXPECTED_VOCABULARY,
executed_terms=None,
provider_complete=True
):
findings = []
if (
not original
or len(set(original)) != len(original)
or any(not value.strip() for value in original)
):
findings.append("INVALID_ORIGINAL_QUERY")
if not set(required_exclusions).issubset(
set(actual_exclusions)
):
findings.append("EXCLUSION_REMOVED")
seen = set()
accepted = set(original)
for mapping in mappings:
if mapping.original not in original:
findings.append("UNKNOWN_ORIGINAL_CONCEPT")
if mapping.relationship not in ALLOWED_RELATIONSHIPS:
findings.append("INVALID_RELATIONSHIP_TYPE")
if mapping.decision not in ALLOWED_DECISIONS:
findings.append("INVALID_DECISION")
if (
not mapping.candidate.strip()
or not mapping.explanation.strip()
or not mapping.vocabulary_revision.strip()
):
findings.append("INCOMPLETE_MAPPING_PROVENANCE")
if mapping.vocabulary_revision != expected_revision:
findings.append("STALE_VOCABULARY_REVISION")
key = (
mapping.original.casefold(),
mapping.candidate.casefold()
)
if key in seen:
findings.append("DUPLICATE_MAPPING")
seen.add(key)
if mapping.decision == "accepted":
if mapping.relationship not in EQUIVALENCE_CANDIDATES:
findings.append("SEMANTIC_SCOPE_DRIFT")
else:
accepted.add(mapping.candidate)
if executed_terms is not None:
actual = set(executed_terms)
if not set(original).issubset(actual):
findings.append("ORIGINAL_TERM_REMOVED")
if not accepted.issubset(actual):
findings.append("ACCEPTED_TERM_MISSING")
if not actual.issubset(accepted):
findings.append("UNAPPROVED_TERM_EXECUTED")
if not provider_complete:
findings.append("INCOMPLETE_PROVIDER_COVERAGE")
return {
"classification": "synthetic",
"status": "FAIL" if findings else "PASS",
"diagnostic_codes": sorted(set(findings)),
"original_concepts": list(original),
"required_exclusions": list(required_exclusions),
"actual_exclusions": list(actual_exclusions),
"accepted_terms": sorted(accepted),
"real_vocabulary_resolution": "NOT_TESTED",
"provider_query_semantics": "NOT_TESTED",
"scientific_mapping_review": "NOT_TESTED",
"production_acceptance": "NOT_TESTED"
}
def main():
accepted_terms = (
"enhanced rock weathering",
"accelerated rock weathering",
"carbon dioxide removal",
"CDR"
)
valid = diagnose(
executed_terms=accepted_terms
)
unsafe = diagnose(
actual_exclusions=(),
executed_terms=accepted_terms + (
"rock weathering",
)
)
print(json.dumps({
"reference_case": valid,
"negative_case": unsafe
}, indent=2))
if __name__ == "__main__":
main()
The module checks whether original concepts, required exclusions, mapping decisions, vocabulary revisions, and executed terms remain consistent.
It does not parse an actual Boolean query, verify real reviewer authorization, inspect scientific vocabulary definitions, or communicate with a search provider.
Its executed_terms argument represents a synthetic, already extracted set of terms. In a real system, executed-query reconciliation must also inspect Boolean structure, field restrictions, and provider-specific semantics.
17. Run the diagnostic example
python query_diagnostics.py
Expected reference results:
Reference case:
PASS
Negative case:
FAIL
Negative diagnostic codes:
EXCLUSION_REMOVED
UNAPPROVED_TERM_EXECUTED
Real vocabulary resolution:
NOT_TESTED
Scientific mapping review:
NOT_TESTED
Production acceptance:
NOT_TESTED
The negative case deliberately removes a required exclusion and inserts a rejected broader term into the executed expression.
This demonstrates why an expansion must be assessed against both its original research restrictions and its approved mapping ledger.
18. Implement regression and negative tests
Save the following as test_query_diagnostics.py.
from dataclasses import replace
import unittest
from query_diagnostics import (
ORIGINAL,
EXCLUSIONS,
MAPPINGS,
EXPECTED_VOCABULARY,
diagnose
)
EXECUTED = (
"enhanced rock weathering",
"accelerated rock weathering",
"carbon dioxide removal",
"CDR"
)
class QueryDiagnosticTests(unittest.TestCase):
def assert_problem(self, code, **kwargs):
result = diagnose(**kwargs)
self.assertEqual(result["status"], "FAIL")
self.assertIn(
code,
result["diagnostic_codes"]
)
def test_valid_fixture(self):
result = diagnose(
executed_terms=EXECUTED
)
self.assertEqual(result["status"], "PASS")
def test_original_preserved(self):
result = diagnose()
self.assertEqual(
result["original_concepts"],
list(ORIGINAL)
)
def test_required_exclusion_removed(self):
self.assert_problem(
"EXCLUSION_REMOVED",
actual_exclusions=()
)
def test_broader_term_accepted(self):
changed = list(MAPPINGS)
changed[1] = replace(
changed[1],
decision="accepted"
)
self.assert_problem(
"SEMANTIC_SCOPE_DRIFT",
mappings=tuple(changed)
)
def test_related_term_accepted(self):
changed = list(MAPPINGS)
changed[3] = replace(
changed[3],
decision="accepted"
)
self.assert_problem(
"SEMANTIC_SCOPE_DRIFT",
mappings=tuple(changed)
)
def test_stale_vocabulary(self):
changed = list(MAPPINGS)
changed[0] = replace(
changed[0],
vocabulary_revision="old-v0"
)
self.assert_problem(
"STALE_VOCABULARY_REVISION",
mappings=tuple(changed)
)
def test_missing_provenance(self):
changed = list(MAPPINGS)
changed[0] = replace(
changed[0],
explanation=""
)
self.assert_problem(
"INCOMPLETE_MAPPING_PROVENANCE",
mappings=tuple(changed)
)
def test_unknown_original_concept(self):
changed = list(MAPPINGS)
changed[0] = replace(
changed[0],
original="unknown concept"
)
self.assert_problem(
"UNKNOWN_ORIGINAL_CONCEPT",
mappings=tuple(changed)
)
def test_duplicate_mapping(self):
self.assert_problem(
"DUPLICATE_MAPPING",
mappings=MAPPINGS + (MAPPINGS[0],)
)
def test_invalid_relationship(self):
changed = list(MAPPINGS)
changed[0] = replace(
changed[0],
relationship="scientifically_proven"
)
self.assert_problem(
"INVALID_RELATIONSHIP_TYPE",
mappings=tuple(changed)
)
def test_unapproved_executed_term(self):
self.assert_problem(
"UNAPPROVED_TERM_EXECUTED",
executed_terms=EXECUTED + (
"rock weathering",
)
)
def test_original_term_removed(self):
self.assert_problem(
"ORIGINAL_TERM_REMOVED",
executed_terms=(
"accelerated rock weathering",
"carbon dioxide removal",
"CDR"
)
)
def test_accepted_term_missing(self):
self.assert_problem(
"ACCEPTED_TERM_MISSING",
executed_terms=ORIGINAL
)
def test_partial_provider_coverage(self):
self.assert_problem(
"INCOMPLETE_PROVIDER_COVERAGE",
provider_complete=False
)
def test_deterministic_result(self):
first = diagnose(
executed_terms=EXECUTED
)
second = diagnose(
executed_terms=EXECUTED
)
self.assertEqual(first, second)
if __name__ == "__main__":
unittest.main()
19. Run the regression suite
python -m unittest -v test_query_diagnostics.py
The suite defines fifteen reference tests.
They cover:
- Correct synthetic mapping behavior.
- Original-query preservation.
- Missing exclusions.
- Unapproved broader and related mappings.
- Stale vocabulary revisions.
- Missing mapping provenance.
- Unknown original concepts.
- Duplicate mappings.
- Invalid relationship types.
- Unapproved terms in executed queries.
- Missing original and accepted terms.
- Incomplete provider coverage.
- Deterministic diagnostics.
These are local reference test definitions. They are not represented as executed tests against the deployed Sustainable Catalyst platform.
Passing the synthetic suite does not prove scientific mapping correctness, provider-specific Boolean fidelity, trusted authorization, or query persistence.
20. Diagnose retrieval quality using actual evidence
After structural recovery, evaluate whether the corrected query retrieves the intended scientific evidence.
Use a defined relevance assessment where feasible.
| Measure | Original search | Corrected search |
|---|---|---|
| Provider set | Record actual providers | Record actual providers |
| Executed query | Retain exact expression | Retain exact expression |
| Completed coverage | Record execution results | Record execution results |
| Retrieved records | Record count and identities | Record count and identities |
| Relevance judgments | Apply documented criteria | Apply the same criteria |
| Precision | Calculate where supported | Calculate where supported |
| Recall | Evaluate against defined reference collection | Use the same reference collection |
| Exclusion integrity | Original criteria retained | Confirm corrected criteria |
A query returning more records after correction may represent improved recall, reduced precision, broader scope, or different provider coverage.
Use actual relevance judgments and coverage evidence to distinguish these explanations.
21. Recover safely from incorrect expansion
When a defective expansion has been identified, use a controlled recovery sequence.
- Preserve the original query, affected expansion revision, and provider execution receipts.
- Identify the specific unsupported mapping, missing restriction, provider translation error, or authorization defect.
- Determine whether affected search results were saved to Library or used by downstream research.
- Stop affected publication or automatic source-selection operations when required.
- Restore the last accepted query revision where the implemented workflow permits it.
- Correct the defective mapping or adapter under the appropriate approval process.
- Regenerate the query from the approved mapping ledger.
- Reexecute the search under documented provider conditions.
- Compare results and exclusions with the original research protocol.
- Review downstream sources, analyses, and publications affected by the erroneous expansion.
- Record the correction, evidence, and reviewer decision.
Do not delete or rewrite accepted Library sources merely because they were originally discovered using a defective query.
Instead, assess their relevance and record any appropriate correction to the source-selection or research evidence record.
22. Handle persistence, caching, and retry failures
Saved queries and expansion decisions may be cached, indexed, or persisted in separate components.
If the interface shows an outdated query:
- Compare the displayed revision with the authoritative stored revision.
- Inspect relevant cache or index state.
- Confirm the active project and authenticated identity.
- Check whether a newer mapping revision was applied.
- Verify that the interface is not combining terms from different saved revisions.
Do not broadly clear production caches or overwrite stored queries without first identifying the responsible state.
Query execution may be read-only, but saving query revisions, changing mappings, or publishing search methods can involve writes.
Before repeating an uncertain write, reconcile its operation identifier, expected revision, commit state, and documented idempotency behavior.
23. Preserve a sanitized incident receipt
A troubleshooting receipt should record the affected query and its recovery history.
Illustrative JSON:
{
"schema_version": "example-1.0",
"workflow": "query_concept_expansion_troubleshooting",
"classification": "synthetic",
"case_id": "synthetic-query-incident-001",
"original_query": {
"revision": "original-v1",
"concepts": [
"enhanced rock weathering",
"carbon dioxide removal"
],
"exclusions": [
"outside-study-scope"
]
},
"affected_expansion": {
"revision": "expanded-v2",
"vocabulary_revision": "synthetic-v1",
"failure_class": "semantic_scope_drift",
"unapproved_term": "rock weathering"
},
"diagnosis": {
"root_cause_confirmed": false,
"downstream_impact_assessed": false
},
"acceptance": {
"original_query_integrity": "not_tested",
"mapping_semantics": "not_tested",
"mapping_provenance": "not_tested",
"exclusions": "not_tested",
"boolean_logic": "not_tested",
"provider_execution": "not_tested",
"retrieval_quality": "not_tested",
"authorization": "not_tested",
"persistence": "not_tested",
"scientific_review": "not_tested",
"production_runtime": "not_tested"
},
"publication_approval": "not_approved",
"release_decision": "NO_GO"
}
This is an illustrative diagnostic contract and not a verified Sustainable Catalyst API or database schema.
Actual incident records should include authorized reviewer decisions, source-code revisions, executed query evidence, recovery actions, and remaining limitations.
24. Technical and scientific acceptance matrix
| Criterion | Pass condition | Evidence |
|---|---|---|
| Original research context | Research purpose and intended scope remain identifiable | Research protocol |
| Original query | Starting expression preserved exactly | Versioned query record |
| Mapping semantics | Accepted terms reflect approved scientific relationships | Terminology and domain review |
| Vocabulary provenance | Mapping source and revision verified | Vocabulary resolution |
| Expansion transparency | Every change and candidate decision visible | Expansion ledger |
| Exclusion integrity | No original exclusions silently removed | Query comparison |
| Boolean logic | Logical grouping and restrictions preserved | Parsed query comparison |
| Provider translation | Actual provider syntax reflects intended logic | Executed provider queries |
| Provider coverage | Incomplete or failed providers disclosed | Coverage receipts |
| Retrieval evaluation | Corrected search assessed with suitable relevance evidence | Relevance judgments and metrics |
| Source provenance | Retrieved sources retain authoritative identities | Source reconciliation |
| Authorization | Trusted access and project boundaries enforced | Backend security tests |
| Persistence | Corrected query revision survives supported reload and session boundaries | Persistence and replay tests |
| Scientific impact | Affected analyses and publications assessed | Impact review |
| Recovery | Defect corrected without unsupported data mutation | Recovery receipt |
| Runtime acceptance | Actual deployed behavior independently verified | API and browser tests |
Acceptance rule: Record each criterion as Pass, Fail, Not Tested, or Not Applicable. Required unresolved criteria prevent full recovery acceptance.
Correct software behavior does not substitute for scientific review of the terminology relationships and research meaning.
25. Sustainable Catalyst cross-application responsibilities
| Application | Intended responsibility |
|---|---|
| Unified Discovery | Preserve query expansions, mapping decisions, provider execution, and diagnostic evidence |
| Library | Maintain authoritative retrieved sources, source revisions, and rights |
| Research Lab | Evaluate scientific terminology and relevance of retrieved evidence |
| Workbench | Support reproducible retrieval comparisons and related analytical records |
| Site Intelligence | Preserve geographic and environmental terminology context where relevant |
| Decision Studio | Identify models or decisions affected by changes in the evidence base |
| Workspace | Manage project ownership, saved query revisions, incidents, and approvals |
| Research | Review published research affected by incorrect discovery methodology |
| Platform Core | Enforce trusted identity, organization boundaries, and authorization |
These represent intended architectural responsibilities, not verified production integrations.
26. Required implementation and source audit
Before certifying this troubleshooting procedure, inspect:
- Actual Unified Discovery owning repository and commit.
- Query normalization and parsing code.
- Terminology registry and vocabulary connectors.
- Actual concept-mapping types and revision model.
- Original-query and exclusion preservation.
- Query-generation and Boolean rendering logic.
- Provider-specific query translation.
- Provider execution, coverage, and error reporting.
- Actual mapping approval and trusted authorization.
- Saved-query identity, revisions, and persistence.
- Search cache and index behavior.
- Source-to-Library relationships.
- Executed negative and regression tests.
- Authenticated browser acceptance.
- Migration and recovery evidence where persistence is affected.
- Scientific terminology review and publication gates.
- Known limitations or disabled capabilities.
Attach actual code paths, commits, contracts, CI receipts, staging revisions, and runtime observations before labeling any specific interface or recovery action as implementation verified.
27. Escalation and scientific impact
Escalate when:
- A private query or research source becomes accessible to an unauthorized owner.
- Mappings repeatedly introduce unapproved scientific concepts.
- Original exclusions disappear from executed searches.
- Provider translation systematically alters Boolean logic.
- Saved query revisions cannot be reconciled.
- Scientific literature reviews or publications depend on incorrectly expanded queries.
- Recovery requires destructive database or cache operations.
- Incorrect expansion affects multiple research projects.
Preserve the last accepted query and relevant execution evidence. Suspend affected automated source selection or publication operations if necessary.
Escalate only sanitized diagnostic information to the responsible component owner. Do not disclose credentials, private research protocols, protected source data, or confidential project relationships in public tickets.
28. Technical and scientific references
- World Wide Web Consortium (W3C) (2009). SKOS Simple Knowledge Organization System Reference. Available at: https://www.w3.org/TR/skos-reference/.
- World Wide Web Consortium (W3C) (2009). SKOS Simple Knowledge Organization System Primer. Available at: https://www.w3.org/TR/skos-primer/.
- Rethlefsen, M.L. et al. (2021). ‘PRISMA-S: An extension to the PRISMA Statement for Reporting Literature Searches in Systematic Reviews’, Journal of the Medical Library Association, 109(2), pp. 174–200. Available at: https://doi.org/10.5195/jmla.2021.962.
- Robertson, S.E. and Zaragoza, H. (2009). ‘The Probabilistic Relevance Framework: BM25 and Beyond’, Foundations and Trends in Information Retrieval, 3(4), pp. 333–389. Available at: https://doi.org/10.1561/1500000019.
- World Wide Web Consortium (W3C) (2013). PROV-O: The PROV Ontology. Available at: https://www.w3.org/TR/prov-o/.
- Nottingham, M., Wilde, E. and Dalal, S. (2023). Problem Details for HTTP APIs. RFC 9457. Available at: https://www.rfc-editor.org/rfc/rfc9457.html.
- Fielding, R., Nottingham, M. and Reschke, J. (2022). HTTP Semantics. RFC 9110. Available at: https://www.rfc-editor.org/rfc/rfc9110.html.
- OWASP Foundation (2023). API Security Top 10. Available at: https://owasp.org/API-Security/.
- Python Software Foundation (n.d.). dataclasses — Data Classes. Available at: Python documentation.
- Python Software Foundation (n.d.). unittest — Unit Testing Framework. Available at: Python documentation.
29. Completion and verification record
| Field | Required record |
|---|---|
| Incident identifier | Unique diagnostic or support case |
| Original query | Authoritative original expression and revision |
| Affected expansion | Query revision and accepted, rejected, or pending mappings |
| Scientific context | Research question, project, owner, and scope |
| Mapping provenance | Terminology source and revision |
| Root cause | Confirmed failure or unresolved hypothesis |
| Semantic integrity | Pass, Fail, or Not Tested |
| Exclusion integrity | Pass, Fail, or Not Tested |
| Boolean query fidelity | Pass, Fail, or Not Tested |
| Provider execution | Pass, Fail, or Not Tested |
| Provider coverage | Completed, failed, or partial providers |
| Retrieval evaluation | Relevance assessments and limitations |
| Authorization and rights | Pass, Fail, or Not Tested |
| Query persistence | Pass, Fail, or Not Tested |
| Recovery action | Actual authorized correction and receipt |
| Regression evidence | Executed tests and implementation revision |
| Scientific impact | Review of affected analyses and publications |
| Runtime acceptance | Actual API and browser verification |
| Reviewer | Responsible reviewer and date |
| Outstanding limitations | Unresolved scientific, semantic, or technical risks |
Completion criterion: A query concept expansion defect is resolved when the original research meaning and exclusions are preserved; added terms are traceable to appropriate terminology evidence and review decisions; Boolean logic and provider-specific execution are correctly reconciled; retrieval changes and incomplete coverage are disclosed; saved query revisions remain reproducible; and affected research outputs have received the required scientific and operational review.
Scientific limitation: Technically correct terminology mappings and successful search execution do not prove that retrieved sources are scientifically credible, methodologically suitable, or sufficient to establish a research claim. Those judgments require separate research appraisal.
Current implementation status: Troubleshooting methodology, semantic-drift and exclusion-integrity checks, terminology revision diagnostics, provider-query considerations, synthetic Python diagnostic model, fifteen regression-test definitions, safe recovery requirements, and proposed acceptance criteria documented. No specific Sustainable Catalyst Unified Discovery concept-expansion engine, controlled vocabulary registry, provider-query translator, saved-query database, or production recovery procedure is certified without source audit, executed integration tests, authenticated runtime verification, and scientific acceptance.
