hybrid-search-implementation
Pass
Audited by Gen Agent Trust Hub on Apr 18, 2026
Risk Level: SAFECOMMAND_EXECUTIONEXTERNAL_DOWNLOADSPROMPT_INJECTION
Full Analysis
- [COMMAND_EXECUTION]: The PostgreSQL hybrid search template in
resources/implementation-playbook.mddynamically constructs SQLWHEREclauses using f-strings for dictionary keys in thefilter_metadataparameter. This pattern allows for potential SQL injection if the keys are sourced from untrusted user input. - [EXTERNAL_DOWNLOADS]: The
PostgresHybridSearch.search_with_rerankmethod inresources/implementation-playbook.mdfetches a pre-trained model from Hugging Face's public repository (cross-encoder/ms-marco-MiniLM-L-6-v2) for reranking search results. - [PROMPT_INJECTION]: The skill architecture is designed to process untrusted data (search queries and document content) within a RAG pipeline, presenting a surface for indirect prompt injection.
- Ingestion points: User-provided search queries and document content retrieved from databases or Elasticsearch as seen in
resources/implementation-playbook.md. - Boundary markers: None identified in the provided implementation templates.
- Capability inventory: Database querying via
asyncpg, search operations viaelasticsearch, and local model inference viasentence_transformers. - Sanitization: No input sanitization or instruction filtering is implemented in the provided code templates.
Audit Metadata