knowledge_query
Answer questions using knowledge base (uploaded documents, handbooks, files). Use for QUESTIONS that need an answer synthesized from documents or messages. Returns an evidence pack with source citations, KG entities, and extracted numbers. Modes: - 'auto' (default): Smart routing — works for most...
This record as markdown: /tools/io-github-saloprj-dialogbrain/knowledge-query.md
What knowledge_query does on Dialogbrain
AI agents call knowledge_query to retrieve information from Dialogbrain without modifying anything. It is typically the context-gathering step in research, monitoring, and reporting workflows, before the agent takes action elsewhere.
| Parameter | Type | Required | Description |
|---|---|---|---|
date_to | string | — | Filter messages until this date (ISO format: YYYY-MM-DD). |
file_ids | array | — | Specific file IDs to search within (for pinned files) |
question | string | Yes | The question to answer from user's knowledge base. Required even for entity queries. |
date_from | string | — | Filter messages from this date (ISO format: YYYY-MM-DD). Use for time-based queries like 'this week', 'last month'. |
thread_id | string | — | Limit search to a specific thread/chat |
max_sources | integer | — | Maximum number of sources to consider (1-10) |
needs_aggregation | boolean | — | True if query asks for totals/sums/counts. |
include_relationships | boolean | — | Include KG relationships in answer (default: true for entity mode) |
Parameters from the server's own tool schema.
Why knowledge_query is rated Low
This tool exclusively reads and searches existing data (uploaded documents, handbooks, files, messages) to synthesize answers. It returns citations and extracted information but does not create, modify, delete, or execute external operations. The multiple query modes (auto, rag, entity, relationship) are all search/retrieval patterns. No destructive, financial, or execution capabilities are described.
From the tool's definition Tool performs 'Answer questions using knowledge base', 'Semantic search across documents & messages', returns 'evidence pack with source citations' — all retrieval operations with no modification or side effects.
Attacks that exploit this kind of access
The rule that runs knowledge_query safely
PolicyLayer is an MCP gateway: it sits between your AI agents and Dialogbrain, and checks every tool call against a rule you set before the call runs. Nothing changes on the server itself. For knowledge_query, this is the rule to start with:
knowledge_query is read-only, so it stays allowed. Everything else on the server is denied unless you say otherwise.
The button opens the PolicyLayer dashboard: create your workspace, connect Dialogbrain, apply this rule, and every knowledge_query call is checked against it from then on.
Questions about knowledge_query
Answer questions using knowledge base (uploaded documents, handbooks, files). Use for QUESTIONS that need an answer synthesized from documents or messages. Returns an evidence pack with source citations, KG entities, and extracted numbers. Modes: - 'auto' (default): Smart routing — works for most questions - 'rag': Semantic search across documents & messages - 'entity': Entity-centric queries (e.g., 'Tell me about [entity]') - 'relationship': Two-entity queries (e.g., 'How is [entity A] related to [entity B]?') Examples: - 'What did we discuss about the budget?' → knowledge.query - 'Tell me about [entity]' → knowledge.query mode=entity - 'How is [A] related to [B]?' → knowledge.query mode=relationship NOT for finding/listing files, threads, or links — use search.files / search.threads / search.links for that. It is categorised as a Read tool in the Dialogbrain MCP Server, which means it retrieves data without modifying state.
knowledge_query accepts 8 parameters: date_to, file_ids, question, date_from, thread_id, max_sources, needs_aggregation, include_relationships. Required: question. The full parameter table on this page comes from the server's own tool schema.
Register the Dialogbrain MCP server in PolicyLayer and add a rule for knowledge_query: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Dialogbrain. Nothing to install.
knowledge_query is a Read tool with low risk. Read-only tools are generally safe to allow by default.
Yes. Add a rate_limit block to the knowledge_query rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for knowledge_query. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
knowledge_query is provided by the Dialogbrain MCP server (https://api.dialogbrain.com/mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
More on Dialogbrain, and thousands of servers like it.
This server
Across the catalogue